Archived

This topic is now archived and is closed to further replies.

  • 0

jQuery?

Question

Posted · Report post

Any idea why this script:

<script type="text/javascript">
	$(document).ready(function()
	{
	  $(".resSub").hide();
	  $(".resHead").click(function()
	  {
	    $(this).next(".resSub").slideToggle(600);
	  });
	});
	</script>

Wouldn't be working on this page: http://beta.wtcut.com/asia The script works fine outside of wordpress. What it does is Hides the content of the div's with the class resSub, and shows them when you click the header above the corresponding div. So for that page, you would click on China, and the links would show.

Share this post


Link to post
Share on other sites

5 answers to this question

Posted · Report post

If you've set up in an identical fashion outside of WP and it worked then you may have a plug-in conflict. We might have gone through this before, but plug-ins really can be both amazing and nightmares at the same time. Do you have any plugins that rely on similar jquery?

Share this post


Link to post
Share on other sites

Posted · Report post

I've got two plugins that use some jquery, a shadowbox plugin and neg gen gallery... disabling both doesn't solve the problem however. You think it's because a plugin is calling another version (or a duplicate) of the jquery library? The shadowbox effects work fine though.

Share this post


Link to post
Share on other sites

Posted · Report post

Have you tried asking this question on a jquery forum? That might be a better place. The only thing I can think of is that the jquery's not being loaded.

Share this post


Link to post
Share on other sites

Posted · Report post

It's hard for me to say what causes a problem like this, but plug-ins are some of the usual suspects. Are you sure that the jquery is being loaded onto the page? I tried looking, but got a 404 on the page you provided

Share this post


Link to post
Share on other sites