Hi all, I’m still at cut 'n paste proficiency level with javascript, so when I’m unsure how to resolve this conflict I’m having between two scripts. Hoping someone can help.
I have one script which has a lovely effect of fading all the pages on my site in and out:
<script type="text/javascript">
$(document).ready(function() {
$("body").css("display", "none");
$("body").fadeIn(1000);
$("a").click(function(event){
event.preventDefault();
linkLocation = this.href;
$("body").fadeOut(500, redirectPage);
});
function redirectPage() {
window.location = linkLocation;
}
});
</script>
In addition, I’m integrating the default accordion effect from jquery: http://jqueryui.com/demos/accordion/
The problem I’m having is that I need the links for the accordion (which just link to #) NOT to activate the fade script.
Because it makes things go explode-y when I do.
It seems like I should be able to apply a class to the links I DON’T want to activate the fade and then toss in an if statement in the above code, but I’m not sure how to do that.
Any help would be greatly appreciated!