The last line of nice_menus.js is a setting of the windows onload function, which blows away any other setting.

The new ajax module has a function for this purpose. I tried to paste it in here but I was rejected, so I'll attach the module for your convenience, called 'addLoadEvent'.

CommentFileSizeAuthor
ajax_module-4.6.0.zip8.62 KBbmargulies

Comments

jakeg’s picture

Please note that the latest CVS copy of this module fixes the onLoad problem.

bmargulies’s picture

I tried to see if you had an outstanding issue, but I have not figure out yet how to make drupal's search box sort wheat from chaff. Thanks, benson

z.stolar’s picture

This is not quite exact.
The CVS version uses the addLoadEvent function which is supplied by another module, so using the last cvs version by itself, doesn't guarantee anything.
What I did to overcome this problem was simply to add hook_onload to the module, and that fixes the problem:

<?php 
/*
add hook_onload to load the js (ZS)
*/
function nice_menus_onload(){
	return array('IEHoverPseudo()');
}
?>

This of course obliges me to comment the last line in nice_menus.js

Finally, it works on FF and IE, doesn't contradict with any other scripts and doesn't create errors on IE.

z.stolar’s picture

OK, so it's not THAT succesful, because FF doesn't recognize the function (it's hidden from it), so I added the next lines in nice_menus.js:

else {
	function IEHoverPseudo() {
		return true;
	}
}

now FF doesn't show js problems.

But, still, nice menus and another js I use (nifty corners - http://pro.html.it/articoli/id_599/idcat_31/pag_1/pag.html) - don't work together... damn. I sware it was ok two hours ago...

add1sun’s picture

clearing old issues - 4.6 is deprecated

add1sun’s picture

Status: Active » Closed (won't fix)

clearing old issues - 4.6 is deprecated