I’m working on http://www.aceaofmidland.com/ and I’m trying to use jQuery and jQuery.cycle to cycle through a wordpress custom post type that’s marked up like so:
<div id="toolbar">
<div id="home">
<div id="arrows">
<div class="prev"></div>
<div class="next"></div>
</div>
<div id="descriptions">
<div><strong>Second Home Alert Test</strong><br><p>Testing Testing Testing</p></div>
<div><strong>Test Home Alert Title</strong><br><p>Test Content for homepage alert</p></div>
</div>
</div>
</div>
I’m using the following jQuery to try and activate the cycling. I’m positive I have the scripts correctly loaded, and in order too.
<script type="text/javascript">
jQuery.noConflict();
jQuery(function(){
jQuery('#descriptions').cycle({
next: '.next',
prev: '.prev',
fx: 'fade',
speed: 'fast',
timeout: 5000,
pause: 1
});
});
</script>
If anyone can find out how to get this to work, I’ll be forever grateful. Thank you!
In firebug I get the following errors on pageload:
and
You may want to change this line:
to
https://developer.mozilla.org/en/JavaScript/Reference/Operators/Special/typeof
And that jQuery code should probably be wrapped in a
$(document).ready(function () {});wrapper.I would always try to resolve all errors that occur before the code I am troubleshooting before altering the problematic code itself.