Results 1 to 2 of 2

Thread: DHTML Tooltip help

  1. #1
    Join Date
    Nov 2009
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default DHTML Tooltip help

    http://www.dynamicdrive.com/dynamici...tmltooltip.htm

    onMouseover="ddrivetip('JavaScriptKit.com JavaScript tutorials','yellow', 300)";
    onMouseout="hideddrivetip()"

    ok im trying to add this list to this:
    <div id="NaxxBoss" style="display: none;">
    <ul>
    <li class="style2">Anub'Rekhan</li>
    <li class="style2">Grand Widow Faerlina</li>
    <li class="style2">Maexxna</li>
    <li class="style2">Noth the Plaguebringer</li>
    <li class="style2">Heigan the Unclean</li>
    <li class="style2">Loatheb</li>
    <li class="style2">Instructor Razuvious</li>
    <li class="style2">Gothik the Harvester</li>
    <li class="style2">The Four Horsemen</li>
    <li class="style2">Patchwerk</li>
    <li class="style2">Grobbulus</li>
    <li class="style2">Gluth</li>
    <li class="style2">Thaddius</li>
    <li class="style2">Sapphiron</li>
    <li class="style2">Kel'Thuzad</li>
    </ul>
    </div> to the code above, but it never seems to work , is there a way to put a list into the hover tooltip?

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Displaying rich HTML as the tooltip content is possible, but cumbersome. You basically need to ensure that everything you want shown (in this case, the HTML) is defined on one line, with any special characters backslashed (\). Something like:

    Code:
    onMouseover="ddrivetip('<div id="NaxxBoss" style="display: none;">bla bla bla</div>','yellow', 300)";
    Unless you understand the subtitles of strings in JavaScript, you may not be successfully in entering HTML as the tooltip's contents.

    The good news is, in the next week or so, I'll be releasing a script that supports rich HTML as its contents more readily. Look for it then.
    DD Admin

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
  •