View Full Version : Hide javascript menu from IE9?

07-12-2011, 02:13 AM
I do not understand javascript at all. For about eight years I've had a UDM javascript menu on each of about 200 pages. It consists of a bunch of files that live in the top of my website and are called to each page by four lines of script. I have had only to edit appearance and links in one file. Instructions were to leave the others alone.
The present version of the UDM menu is not free, as the old one was, and if I did buy it I'm not at all sure I'd be able to cope with it. Unless the names of the new files matched those of the old ones, I'd have to go in and edit each page individually.
My problem is that IE9 doesn't display the menu, but does display its background, so there's a big beige block on the top left of every page. It looks bad.
Would I be able to add to one of the files something like a conditional comment such as "If IE9 display none"?
I would be truly grateful for any ideas that would help me fix this.
My site is http://fay.iniminimo.com/
Thank you so much for your interest.

rnd me
07-12-2011, 07:53 PM
ie9 is not really ie, so you need to change the sniffer.

in sniffer.js, modify as follows:


} else if (typeof document.all != "undefined" && !kde) {
exclude = 0;
ie = 1;


} else if ("\v"=="v" && !kde) {
exclude = 0;
ie = 1;

this should cause ie9 (which fixes IE's historical "\v" uniqueness) to show up as something besides IE, though i didn't examine how the script handles unknowns...

07-13-2011, 01:00 AM
Thank you so much, rnd me.
I haven't seen the result yet, because the testing site predicts a 50 minute wait, but I do feel confident.
I really am grateful to you for taking the time.

07-13-2011, 01:39 AM
Thanks. That looks much tidier.