SitePoint Sponsor

User Tag List

Results 1 to 5 of 5

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    Sep 2002
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question on "The JavaScript Anthology": Problem with Double Tooltip Display in IE7

    I made this post November of last year, but I didn't get any responses to it and now I'm faced with the issue again. Hopefully someone can explain it to me and push me in the direction to fix the problem.

    In Chapter 13 of the book (pg 250), there is a great solution for displaying a tooltip when you mouseover an element. I've put this to work on an image map as follows:

    Code:
    <img src="imgsrc.jpg" width="400" height="284" border="0" usemap="#Map" />
     <map name="Map">
       <area shape="rect" coords="241,125,272,157" href="#" class="hastooltip" title="title text goes here">
     </map>
    This works just fine in all browsers, except for IE7. Seems that in IE7, while it displays the tooltip, it also still decides to display the standard browser tooltip as well, so I get this sort of "double tooltip" effect, as I'm calling it.

    Can someone tell me why that is and if there are any suggestions on how to modify the book code so that IE7 doesn't display its own tooltip?

    Thanks!
    Yazmin

  2. #2
    SitePoint Guru
    Join Date
    Mar 2004
    Location
    Earth
    Posts
    406
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It's the same in IE6, and as far as I can tell there isn't a fix - I tried a few variations in the code, but it always does the same thing. Changing the title to something else works, but setting it to nothing just doesn't work when the target is an <area>

  3. #3
    SitePoint Enthusiast
    Join Date
    Sep 2002
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Meh. I just tried that to see what you meant. I also just tried changing "title" to "alt", but for some reason, IE sets the value of the alt attribute as the value of the title attribute and proceeds to display the tooltip.

    You would think there would be a way to control that and wipe it out.

  4. #4
    SitePoint Guru
    Join Date
    Mar 2004
    Location
    Earth
    Posts
    406
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yeah you would .. and it works fine when the element is a link, just not when it's an area. I can only guess that it's an[other] IE bug

    Perhaps there's a way to implement what you want without using an image map?

  5. #5
    SitePoint Enthusiast
    Join Date
    Sep 2002
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well thank you. I appreciate your input - and if you come across a solution, please pass it on.


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
  •