javascript - JQuery Slideshow and MooTools Conflict -


i having problem motools library conflicting jquery library:

here's code:

<script language="javascript" type="text/javascript" src="revamp/js/jquery-1.4.2.js"></script> <script language="javascript" type="text/javascript" src="revamp/js/jquery.blinds-0.9.js"></script>  <script type="text/javascript" src="js/mootools-1.2-core.js"></script>  <script type="text/javascript" src="js/_class.viewer.js"></script>   <script type="text/javascript">//<![cdata[         window.addevent('domready',function(){         var v5 = new viewer($('boxcont').getchildren(),{             mode: 'alpha',             fxoptions: {duration:500},             interval: 6000         });         v5.play(true);            }); </script>   <script type="text/javascript">              $(window).load(function () {                 // start slideshow                 $('.slideshow').blinds();             }) </script> 

if disable mootools, slideshow work (vice versa jquery). tried wrapping jquery around jquery.noconflict(); so:

<script type="text/javascript"> $.noconflict();   jquery(document).ready(function($) {         $(window).load(function () {                 // start slideshow                 $('.slideshow').blinds();             }) }); </script> 

but still mootools dependent script doesn't work. please i'm not familiar jquery/javascript.

thanks!

once call jquery.noconflict(), refer jquery via jquery rather $. $ usable mootools or javascript library.

<script type="text/javascript">     jquery.noconflict();     jquery(document).ready(function() {         jquery(window).load(function () {                 // start slideshow                 jquery('.slideshow').blinds();         })     }); </script> 

if want give jquery name, can following:

<script type="text/javascript">     var jq = jquery.noconflict();     jq(document).ready(function() {         jq(window).load(function () {                 // start slideshow                 jq('.slideshow').blinds();         })     }); </script> 

Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -