VirtueMart Forum

VirtueMart 2 + 3 + 4 => Installation, Migration & Upgrade => Topic started by: huijie on September 21, 2012, 06:42:56 AM

Title: [SOLVED] Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on September 21, 2012, 06:42:56 AM
Ever since I upgraded to virtuemart 2 and Joomala 2.5 from Joomla 1.5, the "add to cart" button has stopped working. I have searched online for a solution to this to no avail. I am not exactly very good with this type of stuff. Your help is very very much appreciated!

When I clicked on "add-to-cart" on the product page, this came out:
Cart

Bill To

Warning: Invalid argument supplied for foreach() in /home/xxx/xxxx.com/components/com_virtuemart/views/cart/tmpl/default_pricelist.php on line 36
Add/Edit billing address information
Ship To
Only in case shipment address is different from billing address,
click »Add/Edit shipment address« button below
Add/Edit shipment address

Thank you so much for all your help in advance!
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on September 21, 2012, 08:06:03 AM
Hello,

What's you vm version? 2.0.10? Your PHP version? It seems that something is wrong because didn't find BTaddress. If you upgrade, did you upgrade also your custom template?

Regards

PS: Please don't make same posts on different topics!
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on September 21, 2012, 11:39:02 AM
Hi Bytelord

My VM version is 2.0.8e. My PHP version is 5.3.13. When we upgraded our version, we changed our template to as well. So i guess it might not be the problem of the template?
May I know what is BTaddress. Have never heard of the term before.

My apologies for posting twice. Was over-zealous in getting help. I will take note in future.
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on September 21, 2012, 13:51:08 PM
Hello,

BT Address is the billing address you complete upon registration (e.g. during checkout). Can you test your VM installation without overrides with the original vm layout?

btw, why you do not upgrade to 2.0.10? There are just few small changes on the layouts...

Regards
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on September 25, 2012, 11:16:38 AM
Hello

Thank you for your help. I apologize for the late reply. Had been real busy. How do i do a testing for my VM installation without overrides with the original vm layout?

I think i might do a upgrade soon. I didnt do it before as I wasnt really aware of it and I am still pretty new to the whole system.
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on September 25, 2012, 12:02:32 PM
Hello,

You could just rename the folder com_virtuemart under your_joomla_folder\templates\your_template\html\com_virtuemart that contains the overrides, also you could try breez with joomla.
You can find here more information about overrides: http://dev.virtuemart.net/projects/virtuemart/wiki/Hints_for_the_use_of_the_template_system

You could use firebug to examine your page: http://forum.virtuemart.net/index.php?topic=102850.0

Regards
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on December 14, 2012, 07:01:44 AM
Hi bytelord. we have upgraded to the latest version of joomla and virtuemart and it is still not working. we are already using the default templates for both joomla and virtuemart. there seems to one other person in the forum that has this problem. u can view the post here at http://forum.virtuemart.net/index.php?topic=104450.msg347421#msg347421

At this point, i am not really sure what to do as we have not tweak or touch any of the virtuemart file. we also try uninstalling and reinstalling virtuemart several times but it does not seem to work. we have been using virtuemart for around 5 years now, and we are always happy w the products and results. is there anybody out there that can shed further light on this?
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: jenkinhill on December 14, 2012, 10:28:44 AM
What is the live site url?

You can turn off the php warning report - http://forum.virtuemart.net/index.php?topic=102555.0   
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on December 14, 2012, 10:52:20 AM
hi jenkinhill, thanks for your reply

may i know what is the use of turning off the php warning report?
the url is http://www.maverickchina.com/component/virtuemart/consumer-payment-trends-in-china-2012-edition-detail?lang=en
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on December 14, 2012, 11:03:17 AM
Fatal error: Call to a member function createPriceDiv() on a non-object in /home/maverickchina/maverickchina.com/components/com_virtuemart/views/cart/tmpl/default_pricelist.php on line 211

this is the 2nd error on the same page.
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on December 14, 2012, 11:21:12 AM
Hello,

Just checked your live url and you are using javascript minifier and compression, this usually cause issues (java script conflicts or the files are been missed) and as i have said too many times on my responses please guys when develope/design a web site DO NOT activate CSS compression, JS compression, Caching Technics ... when your web site is been finished then you could try minify/compression/caching Technics and resolve your issues!!

As i have said again using Helix Framework please disable those settings under your framework/template options...

Your errors using firebug:
ReferenceError: jQuery is not defined
[Break On This Error]    

jQuery.noConflict();

aad62e...7f99.js (line 3)

TypeError: Virtuemart is undefined
[Break On This Error]    

Virtuemart.addtocart_popup = '1' ;

consum...lang=en (line 37)

TypeError: window.addEvent is not a function
[Break On This Error]    

window.addEvent('domready',function(){

consum...lang=en (line 135)

TypeError: window.addEvent is not a function
[Break On This Error]    

window.addEvent('domready',function(){

Regards
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on December 17, 2012, 02:45:45 AM
Dear Bytelord

Thank you very much. Turning off JSquery and CSS compression seemed to have helped us solve part of the problem. Now, we can actually access the "Add to Cart" page normally.

However, when we do a "Check Out" at the page, it will timed out. In fact, all other features on the "Add to Cart" page will eventually lead to a time out. This seems to be the last hurdle before restoring my shopping cart. 
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on December 17, 2012, 10:10:18 AM
Hello,

Yes as i see there is not javascript conflicts now. For the cart issue that when you checkout never goes to next step, is the a reason that you enabled SSL? Please disable it from backend Configuration -> Shop please uncheck the option  Enable SSL for sensitive areas (recommended).

Regards
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: huijie on December 18, 2012, 02:49:58 AM
Hi Bytelord

Thank you so much. Your method seems to have solved the problem that I have been facing for the past few months. Thank you so much for making such a supportive virtuemart community and I truly and greatly appreciate it. Thank you!!!!
Title: Re: Problem with "Add to Cart" on Virtue. Appreciate help
Post by: bytelord on December 18, 2012, 03:02:20 AM
Nice :)

You are welcome.