Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Rich HTML Balloon Tooltip Load First on Page?

  1. #1
    Join Date
    Jun 2008
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Rich HTML Balloon Tooltip Load First on Page?

    1) Script Title:

    Rich HTML Balloon Tooltip

    2) Script URL (on DD):

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

    3) Describe problems:

    This script is working fine for me - I'm using it provide a hover menu interface for my site.

    My question is: Is it possible to control when exactly the tooltip is loaded by the browser. We have some web user tracking software that downloads an image for every page on our site. The problem is that the tooltips don't appear when they should until after everything else on the page (including the tracking image) loads.

    Is there a way to force the tooltips to load first?

    Thanks

    Jason

  2. #2
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    Can we see the page with the problematic code please? That will give us an idea of how its placed and how it should be placed.
    Jeremy | jfein.net

  3. #3
    Join Date
    Jun 2008
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Sure - http://newsite.farrapc.com/about-us is one example, but it could be any page on the site. When you hover over the Products and Applications buttons at the top, you'll see the tooltip appear, but it won't appear until everything else is loaded.

    BTW, the problem is only visible from IE, not FF. This is because the tracking script/image only works in IE.

    Thanks!

  4. #4
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    So the drop down menu is the tooltip? I don't think that its the best place to put a tooltip, try using one of the following:
    http://www.dynamicdrive.com/dynamici...anylinkcss.htm
    http://www.dynamicdrive.com/dynamici...menu/index.htm
    Jeremy | jfein.net

  5. #5
    Join Date
    Jan 2006
    Location
    Ft. Smith, AR
    Posts
    795
    Thanks
    57
    Thanked 129 Times in 116 Posts

    Default

    I would have to agree with Nile, it's not technically a "submenu" script. It's more for when someone hovers over a link to give a bit more description... However, this is an interesting way of using it. Can't say that I've seen anyone else do it this way.

    But Nile is right, the best bet (and the most expandable) would be to use an actual "menu" script.
    --------------------------------------------------
    Reviews, Interviews, Tutorials, and STUFF
    --------------------------------------------------
    Home of the SexyBookmarks WordPress plugin

  6. #6
    Join Date
    Jun 2008
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Guys, thanks for your help, but I really need to stick with the tooltip. There aren't going to be any further submenus, so the fact that it's not really expandable isn't an issue for me at this point.

    I found this script the easiest to integrate with our site's considerable css demands, so I don't think switching would be the best thing.

    Is there a way to control the timing of when the tooltip's loaded?

    Thanks,

    Jason

  7. #7
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    Find this in the code:
    Code:
    if (window.addEventListener)
    window.addEventListener("load", initalizetooltip, false)
    else if (window.attachEvent)
    window.attachEvent("onload", initalizetooltip)
    else if (document.getElementById)
    window.onload=initalizetooltip
    And replace it with this:
    Code:
    initalizetooltip();
    I don't know if it will work.
    But I hope it does,
    Nile
    Jeremy | jfein.net

  8. #8
    Join Date
    Jun 2008
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Nile,

    Thanks for the response.

    I don't think it worked. The tooltip still displays fine, but it doesn't appear until all other items on the page are loaded.

    Thanks,

    Jason

  9. #9
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    I did a little testing by making my own little code:
    Code:
    <script type="text/javascript">
    var deter;
    function seeThro(){
    return ((deter) ? "true" : "false");
    }
    window.onload = function(){
    deter = true;
    }
    window.onclick = function(){
    if(deter){
    alert("True");
    }
    else {
    alert("False");
    }
    }
    alert(seeThro());
    </script>
    <img src="http://www.astro.uio.no/ita/artikler/tema/new_horizons/images/JupiterIo010807.jpg" />
    <img src="http://www.columbia.edu/itc/mealac/pritchett/00maplinks/overview/world2003/world2003.jpg" />
    That test was positive(it worked as planned).

    In your case I really don't think that there's away to get it to work before onload. I'm sorry. Was there a specific reason why you needed it to work before onload?
    Last edited by Nile; 08-11-2008 at 12:48 PM.
    Jeremy | jfein.net

  10. #10
    Join Date
    Jun 2008
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks so much for all the work you put into this!

    The reason I need it is because our team's afraid that a user won't even know they can select one of these 'dropdown tooltips', since they won't appear until all page content is loaded - which could take awhile b/c of the tracking image that I mentioned.

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
  •