SitePoint Sponsor

User Tag List

Results 1 to 9 of 9
  1. #1
    SitePoint Enthusiast
    Join Date
    Feb 2005
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    IE Javascript issues

    Okay, I'm having major issues with IE and javascript. My page is looking good in FF, mozilla and even works in Opera, but for some reason the Javascript won't co-operate in IE. Someone told me that IE is using a slightly different scriptto the "accepted" javascript. Is this true? How can I get around it?

  2. #2
    I see geek people adris72's Avatar
    Join Date
    Feb 2005
    Location
    NYC
    Posts
    227
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In order to allow us to help you, you should post a link to the html page, or at least, the code that gives you trouble. Other way is almost impossible to know what's going on in you code.

  3. #3
    SitePoint Enthusiast
    Join Date
    Feb 2005
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    http://www.fantastic-fiction.com/help.php

    The offending menu can be found there. Currently it looks like it might have some layout problems as well, but that is porbably just because I have a new compy. Anyhow, the issue is that I've timed the menu because the roll over doesn't seem to give people long enough to access the menu and the roll over for the top menu doesn't seem to work properly, ie it disappears if as soon as the mouse so hoving over it. It is being a right royal pain. Anyhow, the menu is timed to hide if the mouse rolls off the main menu and not the top menu. But IE doesn't even run the timeout script.

    I'd post the script if I had it, but this being a new compy, I haven't actually transferred all my files over just yet.

  4. #4
    I see geek people adris72's Avatar
    Join Date
    Feb 2005
    Location
    NYC
    Posts
    227
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Tested in IE6.0, IE 5.1, Mozilla 1.7, and the last versions of Firefox and Opera.

    It works perfect for me in IE6.0 and even in IE5.1, no disappearing menus, no rollover problems... don't even layout problems.

    The only layout problem I saw was in Opera, the register box is in the top right corner, hidding the header. Other than that, all is ok.

    Maybe some other member can test it and help you with this... good luck anyway.

  5. #5
    SitePoint Evangelist gollux's Avatar
    Join Date
    Feb 2005
    Location
    Oregon, USA
    Posts
    414
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    for some reason IE complains about this line

    setTimeout("hide(menu)",5000);

    with Error: Object doesn't support this property or method.
    Released under the Fiasco Labs Digital Damnation Copywright,
    it's yours to make whatever the 7734 you want with it.

    (c) 2005 Fiasco Labs All Wrongs Reserved

  6. #6
    SitePoint Enthusiast
    Join Date
    Feb 2005
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Layout is only a problem I think because my new compy is widescreen.
    But there were no roll-over problems... I find that strange I am running V6 and unless it is the top menu which is rolled over and off, then the menu stays up. When I get the top menu up but then rolll off the main menu down on to the main section of the page, the top menu stays. I set the time out so that it would disappear in such circumstances, but in IE it doesn't. Well not on my compy at any rate.

  7. #7
    SitePoint Enthusiast
    Join Date
    Feb 2005
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok, that is what I thought, but why doesn't it support the timeout function, and how can I possibly get around it?

  8. #8
    SitePoint Evangelist gollux's Avatar
    Join Date
    Feb 2005
    Location
    Oregon, USA
    Posts
    414
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    It does...

    Quote Originally Posted by Lady Lozza
    Ok, that is what I thought, but why doesn't it support the timeout function, and how can I possibly get around it?
    The problem comes about because you already reference something called menu in another function in the javascript. Change the slowhide function as follows and you should be ok.


    Code:
    function slowhide(id) {
    	menuItem = id;
    	setTimeout("hide(menuItem)",5000);
    }
    For some reason, Mozilla and Firefox probably can keep stuff separate, but IE sees it different and chokes on the variable "menu". Tried it and it's now working in IE 6.
    Released under the Fiasco Labs Digital Damnation Copywright,
    it's yours to make whatever the 7734 you want with it.

    (c) 2005 Fiasco Labs All Wrongs Reserved

  9. #9
    SitePoint Enthusiast
    Join Date
    Feb 2005
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Oh thank you all for your help!
    *does happy dance*
    Cheers,
    Lozza


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
  •