SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Dec 2007
    Posts
    50
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    drop down box vs list

    Hi,

    i have a prob, i am unable to figure it out.

    I have a list of 100 students. I am pulling that list from back-end, i am using Ajax to get the list(this dynamic and sorted).

    to display the names of the students i am using ul (<UL>) tags.

    Is there any way i could make the cursor to jumps to the particular student depend on what key is pressed? let say if we press key "S" it should jump to the student with the name starting with "S"?

    This is possible with the drop down box.

    But, I tried like the below. Then the anchor functionality is not working(b/c of span tags).

    <select>

    <option><span class="student">name1</span> - <span class="age">age</span></option>

    <option><span class="student">name2</span> - <span class="age">age</span></option>

    <option><span class="student">name3</span> - <span class="age">age</span></option>

    </select>


    can this be done by using UL tag?

    any help please?

    Thank you,

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,684
    Mentioned
    99 Post(s)
    Tagged
    4 Thread(s)
    Those are accesskeys that you're wanting to use.
    They mostly work for form elements and links.

    http://www.cs.tut.fi/~jkorpela/forms/accesskey.html
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •