1

How to catch the event when a user pushes the "Next" or "Prev" button when using PhoneGap and JavaScript / jQuery ?

I found several related questions, but the solution is in native code:

how to catch 'next' button on soft keyboard of Android

Android Soft keyboard action button

enter image description here

Community
  • 1
  • 1
Kenci
  • 4,794
  • 15
  • 64
  • 108
  • Why? Maybe, there is another solution. There buttons are for navigationg between input-elements. – Christian Kuetbach Oct 11 '13 at 10:58
  • 1
    Because when I am at the login screen of my application, and push the "Next" button in the password text field, it takes the user to a different screen. I would like to prevent this – Kenci Oct 11 '13 at 11:02
  • Are these buttons for navigation between pages and not for navigating between input elements? Did this change? Thought this would help: http://stackoverflow.com/questions/3895710/explicitly-exclude-an-html-element-from-the-tab-order – Christian Kuetbach Oct 11 '13 at 11:04
  • I believe they are for navigation between input elements, but it changes page when one is at the last input element. I tried that tabindex solution, it doesn't work. – Kenci Oct 11 '13 at 11:06
  • Is there a way to disable the keys perhaps? – Kenci Oct 11 '13 at 11:13
  • I'm writing a general solution (plugin) for this at the moment. The key idea is to have input fields indexed and to compare between them onblur/onfocus how the focused element is related to the blurred one. – Samuli Hakoniemi Oct 11 '13 at 12:12

1 Answers1

0

It will work automatically when it get 2 consecutive text-box

  </div> 
   <ul data-role="listview"  id="singup-form" class="tab"  >
   <li>
    <input type="email" name="text-6" id="email-id" value="" placeholder="Email Address">
    </li>
   <li>
   <input type="password" name="text-6" id="password-id" value="" placeholder="Password">   
    </li>
    </ul> 

Click here! this will help you..

AndroidLad
  • 687
  • 7
  • 14