...

View Full Version : JQuery multiple load problem, help please



CarlMartin10
07-22-2010, 06:23 AM
I am having trouble with a plugin not working, so I contacted the creator, and they said the below. I have no idea how to do what they want. Can anyone help me out?

"Hi The Billboard Family,
We just took a look at your output. It looks like you have jquery loading 3 times, which is not good. This will cause most all jQuery plugins/code to break if you load the jquery library more than once.

It looks like you have it loading with your "Enhanced Search Box" and then again at the end of your head just before your "Cycle.All" script.

Please be sure that the PHP method wp_head() is that LAST piece of code running before your close head tag in your header.php file as well as wp_footer() being the LAST piece of code running before your close body tag in your footer.php file.

I would also recommend running WordPress' wp_enqueu_scripts() method, detailed here by Jamie:
http://getsatisfaction.com/slidedeck/...

Once you get those changes made and jQuery running only once please let us know if you are still having problems.

Cheers! "


MY SITE: http://billboardfamily.com/?page_id=4

SB65
07-22-2010, 07:35 AM
Lines 13 to 80 of your code below:


<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/plugins/slidedeck-lite-for-wordpress/skins/default/skin.css?v=1.1" media="screen" />
<script type='text/javascript' src='http://billboardfamily.com/wp-includes/js/jquery/jquery.js?ver=1.4.2'></script>

<script type='text/javascript' src='http://billboardfamily.com/wp-includes/js/comment-reply.js?ver=20090102'></script>
<script type='text/javascript' src='http://billboardfamily.com/wp-content/plugins/slidedeck-lite-for-wordpress/lib/slidedeck.jquery.lite.pack.js?ver=1.3'></script>
<link rel="EditURI" type="application/rsd+xml" title="RSD" href="http://billboardfamily.com/xmlrpc.php?rsd" />
<link rel="wlwmanifest" type="application/wlwmanifest+xml" href="http://billboardfamily.com/wp-includes/wlwmanifest.xml" />
<link rel='index' title='Billboard Family' href='http://billboardfamily.com' />
<link rel='prev' title='About Us' href='http://billboardfamily.com/?page_id=2' />
<link rel='next' title='Calendar' href='http://billboardfamily.com/?page_id=22' />
<meta name="generator" content="WordPress 3.0" />

<!-- All in One SEO Pack 1.6.12.1 by Michael Torbert of Semper Fi Web Design[330,374] -->
<link rel="canonical" href="http://billboardfamily.com/?page_id=4" />
<!-- /all in one seo pack -->

<!-- Start Of Script Generated By cforms v11.5 [Oliver Seidel | www.deliciousdays.com] -->
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/plugins/cforms/styling/minimal.css" />

<script type="text/javascript" src="http://billboardfamily.com/wp-content/plugins/cforms/js/cforms.js"></script>
<!-- End Of Script Generated By cforms -->

<!-- begin Enhanced Search Box -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){var searchTextDefault = "";var searchBox = $("#s");var searchBoxMain = $("#content .s");searchBox.attr("value", searchTextDefault);searchBoxMain.attr("value", searchTextDefault);searchBoxMain.focus(searchFocus);searchBoxMain.blur(searchBlur);searchBox.focus(s earchFocus);searchBox.blur(searchBlur);function searchFocus(){ $(this).addClass("active"); if($(this).attr("value") == searchTextDefault) $(this).attr("value", ""); };function searchBlur(){ $(this).removeClass("active"); if($(this).attr("value") == "") $(this).attr("value", searchTextDefault); };});
</script>
<!-- end Enhanced Search Box -->

<script type="text/javascript">var AKPC_IDS = "";</script>
<link type="text/css" rel="stylesheet" href="http://billboardfamily.com/wp-content/plugins/wordpress-paypal-shopping-cart/wp_shopping_cart_style.css" />

<script type="text/javascript">
<!--
//
function ReadForm (obj1, tst)
{
// Read the user form
var i,j,pos;
val_total="";val_combo="";

for (i=0; i<obj1.length; i++)
{
// run entire form
obj = obj1.elements[i]; // a form element

if (obj.type == "select-one")
{ // just selects
if (obj.name == "quantity" ||
obj.name == "amount") continue;
pos = obj.selectedIndex; // which option selected
val = obj.options[pos].value; // selected value
val_combo = val_combo + "(" + val + ")";
}
}
// Now summarize everything we have processed above
val_total = obj1.product_tmp.value + val_combo;
obj1.product.value = val_total;
}
//-->
</script>

<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/style.css" />
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/lightbox.css" />

<!--[if lte IE 6]>
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/ie6.css" />
<![endif]-->

<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/jquery.cycle.all.min.js"></script>
<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/scripts.js"></script>



Just as the note says, you are loading (two different versions of) jquery three times. Try deleting the lower two. I'm assuming you have manually added these to your WP header.php file.

CarlMartin10
07-22-2010, 10:18 AM
Lines 13 to 80 of your code below:


<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/plugins/slidedeck-lite-for-wordpress/skins/default/skin.css?v=1.1" media="screen" />
<script type='text/javascript' src='http://billboardfamily.com/wp-includes/js/jquery/jquery.js?ver=1.4.2'></script>

<script type='text/javascript' src='http://billboardfamily.com/wp-includes/js/comment-reply.js?ver=20090102'></script>
<script type='text/javascript' src='http://billboardfamily.com/wp-content/plugins/slidedeck-lite-for-wordpress/lib/slidedeck.jquery.lite.pack.js?ver=1.3'></script>
<link rel="EditURI" type="application/rsd+xml" title="RSD" href="http://billboardfamily.com/xmlrpc.php?rsd" />
<link rel="wlwmanifest" type="application/wlwmanifest+xml" href="http://billboardfamily.com/wp-includes/wlwmanifest.xml" />
<link rel='index' title='Billboard Family' href='http://billboardfamily.com' />
<link rel='prev' title='About Us' href='http://billboardfamily.com/?page_id=2' />
<link rel='next' title='Calendar' href='http://billboardfamily.com/?page_id=22' />
<meta name="generator" content="WordPress 3.0" />

<!-- All in One SEO Pack 1.6.12.1 by Michael Torbert of Semper Fi Web Design[330,374] -->
<link rel="canonical" href="http://billboardfamily.com/?page_id=4" />
<!-- /all in one seo pack -->

<!-- Start Of Script Generated By cforms v11.5 [Oliver Seidel | www.deliciousdays.com] -->
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/plugins/cforms/styling/minimal.css" />

<script type="text/javascript" src="http://billboardfamily.com/wp-content/plugins/cforms/js/cforms.js"></script>
<!-- End Of Script Generated By cforms -->

<!-- begin Enhanced Search Box -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){var searchTextDefault = "";var searchBox = $("#s");var searchBoxMain = $("#content .s");searchBox.attr("value", searchTextDefault);searchBoxMain.attr("value", searchTextDefault);searchBoxMain.focus(searchFocus);searchBoxMain.blur(searchBlur);searchBox.focus(s earchFocus);searchBox.blur(searchBlur);function searchFocus(){ $(this).addClass("active"); if($(this).attr("value") == searchTextDefault) $(this).attr("value", ""); };function searchBlur(){ $(this).removeClass("active"); if($(this).attr("value") == "") $(this).attr("value", searchTextDefault); };});
</script>
<!-- end Enhanced Search Box -->

<script type="text/javascript">var AKPC_IDS = "";</script>
<link type="text/css" rel="stylesheet" href="http://billboardfamily.com/wp-content/plugins/wordpress-paypal-shopping-cart/wp_shopping_cart_style.css" />

<script type="text/javascript">
<!--
//
function ReadForm (obj1, tst)
{
// Read the user form
var i,j,pos;
val_total="";val_combo="";

for (i=0; i<obj1.length; i++)
{
// run entire form
obj = obj1.elements[i]; // a form element

if (obj.type == "select-one")
{ // just selects
if (obj.name == "quantity" ||
obj.name == "amount") continue;
pos = obj.selectedIndex; // which option selected
val = obj.options[pos].value; // selected value
val_combo = val_combo + "(" + val + ")";
}
}
// Now summarize everything we have processed above
val_total = obj1.product_tmp.value + val_combo;
obj1.product.value = val_total;
}
//-->
</script>

<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/style.css" />
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/lightbox.css" />

<!--[if lte IE 6]>
<link rel="stylesheet" type="text/css" href="http://billboardfamily.com/wp-content/themes/mensa/assets/css/ie6.css" />
<![endif]-->

<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/jquery.cycle.all.min.js"></script>
<script type="text/javascript" src="http://billboardfamily.com/wp-content/themes/mensa/assets/js/scripts.js"></script>



Just as the note says, you are loading (two different versions of) jquery three times. Try deleting the lower two. I'm assuming you have manually added these to your WP header.php file.

This is my entire header.php file....I don;t see those repeated in there:


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en-US">

<!-- BEGIN html head -->
<head profile="http://gmpg.org/xfn/11">

<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
<title><?php bloginfo('name'); ?> <?php wp_title(); ?></title>

<?php if (function_exists('wp_enqueue_script') && function_exists('is_singular')) : ?>
<?php if ( is_singular() ) wp_enqueue_script( 'comment-reply' ); ?>
<?php endif; ?>
<?php wp_head(); ?>

<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_url'); ?>/assets/css/style.css" />
<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_url'); ?>/assets/css/lightbox.css" />

<!--[if lte IE 6]>
<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_url'); ?>/assets/css/ie6.css" />
<![endif]-->

<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/assets/js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/assets/js/jquery.cycle.all.min.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/assets/js/scripts.js"></script>

</head>
<!-- END html head -->

<body>

<!-- BEGIN wrapper -->
<div class="wrapper">

<!-- BEGIN header -->
<div id="header">

<div class="search">
<form action="<?php echo get_option('home'); ?>/">
<input type="text" name="s" id="s" value="<?php the_search_query(); ?>" />
<button type="submit">S</button>
</form>
</div>

<div class="subscribe">



<a href="http://www.facebook.com/pages/Saint-Louis-MO/Billboard-Family/112172868831011?v=info&ref=mf" title="Follow Us on Facebook" target="_blank"><img alt="Follow Us on Facebook" src="<?php bloginfo('template_url'); ?>/assets/images/facebook_icon.png"/></a>

<a href="http://www.twitter.com/billboardfamily" title="Follow Us on Twitter" target="_blank"><img alt="Follow Us on Twitter" src="<?php bloginfo('template_url'); ?>/assets/images/twitter_icon.png"/></a>

<a href="http://www.flickr.com/photos/billboardfamily/" title="See Our Flickr Photos" target="_blank"><img alt="See Our Flickr Photos" src="<?php bloginfo('template_url'); ?>/assets/images/flickr_icon.png"/></a>

<a href="http://www.youtube.com/BillboardFamily" title="Check Out Our YouTube Videos" target="_blank"><img alt="Check Out Our YouTube Videos" src="<?php bloginfo('template_url'); ?>/assets/images/youtube_icon.png"/></a>

<a href="http://feeds.feedburner.com/BillboardFamily" title="Subscribe to RSS" target="_blank"><img alt="Subscribe to RSS" src="<?php bloginfo('template_url'); ?>/assets/images/rss_icon.png"/></a>

<br />

<img alt="Follow Us" src="<?php bloginfo('template_url'); ?>/assets/images/followus.png"/>

</div>
<div class="logo">
<h1><a href="<?php echo get_option('home'); ?>"><?php bloginfo('name'); ?></a></h1>
</div>



<ul>

<?php wp_page_menu('include=2,4,22,169,24,26,29,31&sort_column=menu_order'); ?>



</ul>


<div class="break"></div>


<div class="purchase">

<a href="/?page_id=22" title="Purchase Your Day"><img alt="Purchase Your Day" src="<?php bloginfo('template_url'); ?>/assets/images/purchase.png"/></a>
</div>
<!-- END header -->

</div>
<!-- END wrapper -->




<!-- BEGIN wrapper -->
<div class="wrapper">

<!-- BEGIN body -->
<div id="body">

SB65
07-22-2010, 01:23 PM
OK, well, there is a call to jquery, three up from the bottom of your </head>. Looks like the other two are coming from wp_head() and the Enhanced Search Box plugin.

According to http://wordpress.org/extend/plugins/extended-search-plugin/ you should be able to disable the jQuery inclusion via Admin to cope with this precise situation.

I'd suggest removing the call that is included explicitly in header.php and disabling within the Extended Search box, and give that a go.

CarlMartin10
07-22-2010, 01:32 PM
OK, well, there is a call to jquery, three up from the bottom of your </head>. Looks like the other two are coming from wp_head() and the Enhanced Search Box plugin.

According to http://wordpress.org/extend/plugins/extended-search-plugin/ you should be able to disable the jQuery inclusion via Admin to cope with this precise situation.

I'd suggest removing the call that is included explicitly in header.php and disabling within the Extended Search box, and give that a go.


I disabled this in the plugin, that was simple. I then removed this line from my header.php file

<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/assets/js/jquery-1.3.2.min.js"></script>

i then checked the site....and the slideshow at the bottom of the page stopped working, and the original slider I am trying to get to work still did not work, so I'm not sure where to go from here.

CarlMartin10
07-23-2010, 03:00 PM
Still need help.

CarlMartin10
07-25-2010, 08:39 AM
Anyone know what I need to do to fix this???????

CarlMartin10
07-26-2010, 12:12 PM
Anyone know what I need to do to fix this???????

CarlMartin10
08-03-2010, 01:07 AM
This blows. I still do not have a fix for this. Anyone have any ideas?

CarlMartin10
08-09-2010, 08:52 AM
Anyone have a clue on this???

Philip M
08-09-2010, 08:58 AM
Anyone have a clue on this???

I think you can safely say that the answer is - no.

I contacted the creator, and they said "Once you get those changes made and jQuery running only once please let us know if you are still having problems."

CarlMartin10
08-09-2010, 08:59 AM
I think you can safely say that the answer is - no.

I contacted the creator, and they said "Once you get those changes made and jQuery running only once please let us know if you are still having problems."

No doubt. I can not get JQuery to run only once...that's my issue. I have done that MANY times...they obviously can not fix the problem, so they are not contacting me back. I came here to find an expert in their absence. This sucks. Thanks.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum