...

View Full Version : javascript conflict (collapsible and slideshow)



marybeth320
12-13-2010, 09:32 PM
Got some javascript thats conflicting and I'm new to java. One works when I remove the other & vice versa, but not together. Any idea how to make these work? I found what looked like to be an answer, but what I tried didn't work. http://api.jquery.com/jQuery.noConflict/

Any help offered would be appreciated! :thumbsup: Page is here http://lpsolutions-inc.com/newsite/index-test.html The collapsible elements are "About Us" and "Product Lines".



<!--Slideshow-->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"></script>
<script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.2.74.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$('.slideshow').cycle({
fx: 'fade'
});
});
</script>

<!--dropdown-->
<script src="javascripts/prototype.js" type="text/javascript"></script>
<script src="javascripts/scriptaculous.js?load=effects" type="text/javascript"></script>

SB65
12-14-2010, 10:37 AM
You need to change your jQuery to:


$.noConflict();
jQuery(document).ready(function($) {
$('.slideshow').cycle({
fx: 'fade'
});
});

marybeth320
12-14-2010, 05:08 PM
Works perfect, thank you so much!! I've never edited js for something like this so was very lost. Thank you :)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum