JS error when debugging.

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
aravona
Forum Contributor
Posts: 347
Joined: Sat Jun 13, 2009 3:59 pm
Location: England

JS error when debugging.

Post by aravona »

I've got a plugin for a wordpress, wp-ecommerce, I've already posted on their forums and not gotten a response.

The issue is the plugin is giving 'Done but with errors' in IE, so I ran IE's debugging tool. What it doesn't like is the following:

Code: Select all

jQuery("form.product_form").livequery(function(){
			product_id = jQuery('input[name=product_id]',this).val();
			image_element_id = 'product_image_'+product_id;
			jQuery("#"+image_element_id).data("product_id", product_id);
			parent_container = jQuery(this).parents('div.product_view_'+product_id);
			jQuery("div.item_no_image", parent_container).data("product_id", product_id);
	});
The error states: Object doesn't support this property or method wp-e-commerce.js?ver=3.7.58, line 143 character 2

which is the line: jQuery("form.product_form").livequery(function(){

However, when I close the debugger / run the script ... it works fine, infact it works even with the error coming up on the page!

The plugin works completely I don't see why forcing IE to run the script gets rid of the 'done but with errors' message?

Is there a way to get rid of the error notice? Not just on my computer but on all of them? Since the script actually does work? Or does the script need a slight tweak to get rid of it?

Regards,

Aravona

EDIT: Ive read around and found it maybe a jQuery conflict but I don't know how to sort that, if several files call jQuery how can I fix it ?
Post Reply