Results 1 to 2 of 2

Thread: Jim's DHTML Appearing Order

  1. #1
    Join Date
    Oct 2004
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Jim's DHTML Appearing Order

    I have set up jim's DHTML menu, and it works great! (thanks). However, if I load a page that's graphic heavy, ALL of the graphics have to load before the DHTML menu appears. How do I set it up so the menu always appears first (or at least doesn't wait until the whole page is loaded)?

    Thank you.

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Well, it could get ugly in real life but, limited testing shows that removing the:

    Code:
     onload="init()"
    from the body tag and placing this script right after the body tag, like so, may do the trick:

    HTML Code:
    <body>
    <script type="text/javascript">
    init()
    </script>
    I have my doubts though, as it may not give the script time enough to load before calling the init function. It may work for you, locally, or if you have the script cached, but not for first time visitors to your live page. To test, go live and empty your cache first. You may be able to find, by trial and error, a spot further down your page that will give it enough time. If so, I'd move it on down below another element or two just to be on the safe side. In any case, I am not recommending this as foolproof, by any means.
    Last edited by jscheuer1; 05-04-2005 at 07:36 AM.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

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
  •