Contact Us Forum Rules Search Archive
WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-02-2004, 03:57 AM
WebProWorld New Member
 

Join Date: Feb 2004
Posts: 6
rahmatab RepRank 0
Default About tabIndex

Eloo Everybody..

I need some help, all my asp page i already assign the tabIndex. Is there any sample when i click the input type (which tabindex assign to 1) and then the tabIndex focus to the button (which assign tabindex2). Thanks
__________________
No GuT No GloRy
Reply With Quote
  #2 (permalink)  
Old 03-02-2004, 05:21 AM
sijpie's Avatar
WebProWorld Pro
 

Join Date: Sep 2003
Location: Scotland
Posts: 108
sijpie RepRank 0
Default

If your input field is tabindex 1 and your button tabindex 2, then when finished entering text, a tab should bring the button into focus.

You can use some javascript to automatically get your input field into focus after loading the page:

code
<body bgcolor=<%=strAdminBGColor%> onLoad="self.focus();document.login.username.focus ()">

<form action="loginHandler.asp" method="post" name="login">
<table>
<tr class="NormalText">
<td >Username: </td>
<td><input class="NormalText" type=text name='username' >
</td>
</tr>
<tr class="NormalText">
<td>Password: </td>
<td><input class="NormalText" type=password name='password'>

</td>
</tr>
<tr>
<td></td>
<td><input type=submit Value='Log In'>
</td>
</tr>
</table>
</form>
</body>
</html>

the onload script set the focus to the document element login and in particular to the sub element username. So these need to be defined in the form. See all the red bitties. Sorry for the formatting, but apparently color coding deosn't work within a 'code' tag.
__________________
Jaap

PalmVenue
Broekhuizen Paintings
MacSijp

You've done it all
You've broken every code (Steve Harley)
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Tags:



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Search Engine Optimization by vBSEO 3.2.0