Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Dec 2010
    Posts
    14
    Thanks
    0
    Thanked 0 Times in 0 Posts

    adding a tooltip for each option item in drop down menu

    have a scenario where I show a drop-down-with-few-items in a JSP page, to the user.
    The length of few options in the drop down is greater than that of the drop down's, hence our requirement is to show the hovered (not selected) option as tooltip for user's convenience. I cannot use the title attribute option as its not compatible with my web browser

  • #2
    Supreme Master coder! Philip M's Avatar
    Join Date
    Jun 2002
    Location
    London, England
    Posts
    17,733
    Thanks
    202
    Thanked 2,508 Times in 2,486 Posts
    Double-posted at http://forums.89.biz/forums/javascri...ropdown+option


    A few browsers support title in the options list, but most do not. They also do not support mouseover events. If you want to do this, you basically have to code your own select element out of divs, and lists, and links.

    Google for more info.


    All advice is supplied packaged by intellectual weight, and not by volume. Contents may settle slightly in transit.

  • #3
    Regular Coder Krupski's Avatar
    Join Date
    Dec 2010
    Location
    United States of America
    Posts
    505
    Thanks
    39
    Thanked 47 Times in 46 Posts
    Quote Originally Posted by maria_megha View Post
    have a scenario where I show a drop-down-with-few-items in a JSP page, to the user.
    The length of few options in the drop down is greater than that of the drop down's, hence our requirement is to show the hovered (not selected) option as tooltip for user's convenience. I cannot use the title attribute option as its not compatible with my web browser
    Why not just make the select drop-down wider?

    And, if you're having problems with things not working, you are probably using MSIE.

    Fortunately, there is a nice, clean and simple fix for MSIE not supporting hover... check here:

    http://www.xs4all.nl/~peterned/csshover.html

    It's one little file you stick in your CSS and bingo! Hover works in MSIE.
    "Anything that is complex is not useful and anything that is useful is simple. This has been my whole life's motto." -- Mikhail T. Kalashnikov


  •  

    Tags for this Thread

    Posting Permissions

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