开发者

SmoothMenu javascript help

开发者 https://www.devze.com 2022-12-10 07:17 出处:网络
I am using this javascript menu which i bought on the net called SmoothMenu and it works fine in a standalone page..but when incorporated with a master page that is using other javascript files as wel

I am using this javascript menu which i bought on the net called SmoothMenu and it works fine in a standalone page..but when incorporated with a master page that is using other javascript files as well it does not load the javascript which applies the css properties.

I am using mootools javascript file "mootools-1.2.1-core-nc.js" and there is a block of code like

<script type="text/javascript">
    window.addEvent('domready', function() {
        var mySmoothMenu = new SmoothMenu("navigation");
    });
</script>

in the head section , which actually applies some stylesheet to my div with id="navigation" but looking the source with fir开发者_高级运维ebug it results that there is some problem with it as no stylesheet is applied at all. Am I missing some problem here, is there any issue with mootools and jquery???? is there any trick to be added to the above line???

It is really important and any suggestion kindly appreciated.

Edited : In fact I currently discovered that i was using some other version of mootools file for another component and after removing the older one it seems to work but I am still trying to fix things here. I think the two mootools use same behavior and cause ambiguity so the result is total conflict.


Both mootools and jQuery declare a function called $, so they are incompatible out of the box - basically they overwrite each other.


Try this


Or, better, don't use jQuery; if smoothmenu depends on mootools just use mootools


MooTools and jQuery can work together when using MooTools, version 1.2.3 and higher.

0

精彩评论

暂无评论...
验证码 换一张
取 消