L. Brett Sinclair Posted December 23, 2008 Share Posted December 23, 2008 everything was fine and well with the beta 3 version that I had.I decided to upgrade to the final 1.1 and now I can't add ANY products to the cart anymore.I've search and this seems to have been fixed many time already...but this is back again.Please tell what I need to do to fix it - thank you - thank you - thank you Link to comment Share on other sites More sharing options...
chirameto Posted December 24, 2008 Share Posted December 24, 2008 I also get this error with 1.1final. In my case, this error will happen when I try to add product with many attributes but none of them are in stock.Here is the situation:Product A have 2 colors, black in stock, white out of stock ---> add to cart successFire Bug console response return: http://localhost/prestashop/cart.php?_=1230139191382&add;&ajax;=true&qty=1&id_product=37&token=a942e3b5bcf94f4d054d286df7433eaa Product B have 2 colors, none of them instock, ---> TECHNICAL ERROR: unable to add the product. Error thrown: [object XMLHttpRequest] Text status: parsererrorFire Bug console response return: http://localhost/prestashop/cart.php?_=1230139287961&add;&ajax;=true&qty=1&id_product=36&token=a942e3b5bcf94f4d054d286df7433eaa This add to cart error will only happen in the product listing page. It will not appear when I try to add in it's own product page.Fire Bug console response return: http://localhost/prestashop/cart.php?_=1230139421446&add;&ajax;=true&qty=1&id_product=36&token=a942e3b5bcf94f4d054d286df7433eaa&ipa=143 Any body got idea on how to fix this? I will wait a few days before I report it as a bug. Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted December 24, 2008 Author Share Posted December 24, 2008 yes, I have the exact same case except that I do not manage any stock.No trouble at all when adding the product from the listing page as well.Now, when I turn off the AJAX feature, I have a blank page. So, I assume it has to do with a bug in the cart & AJAX...but don't know for sure either. Link to comment Share on other sites More sharing options...
chirameto Posted December 24, 2008 Share Posted December 24, 2008 I think the only logic that broken is the product attribute choosing when no attribute is selected. Everything else is fine and I am certain that stock management is not relate to this issue.I try to turn of AJAX cart off and then add product to cart (from product listing page) in the following scenario:product with multiple attributes, some of the attributes instock ---> it will take you directly to checkout pageproduct with multiple attributes, none of them instock ---> it will take you to product page and await for your choice of attributeI don't get the blank page. and the customers shopping experience is not interrupted by error msg when AJAX is off. So this should be my temporary fix. Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted December 24, 2008 Author Share Posted December 24, 2008 ok - I agree, it has something to do with the attribute somehow. Prestateam : Merry Christmas , get some champagne, foie gras and then maybe give us an answer when you get back? Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted December 30, 2008 Author Share Posted December 30, 2008 bumpany help appreciated thank you Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted January 1, 2009 Author Share Posted January 1, 2009 another bump before I report it to the bug ? Link to comment Share on other sites More sharing options...
oncleroger Posted January 5, 2009 Share Posted January 5, 2009 Hello,Have you define your default transporter ???I think that prestashop try to calculate the price with the default transporter when you add your product to the cart ...Hope this help ...Seb. Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted January 5, 2009 Author Share Posted January 5, 2009 good suggestion but I did - Link to comment Share on other sites More sharing options...
celyd Posted January 10, 2009 Share Posted January 10, 2009 I've the same issue.Firebug show me a redirect (code 302) to the product page when product has combinations.In this case, the response is no longer a JSON structure but a the html page.That cause a parsing error. Link to comment Share on other sites More sharing options...
L. Brett Sinclair Posted January 10, 2009 Author Share Posted January 10, 2009 I have reported it to the bug tracker Link to comment Share on other sites More sharing options...
chirameto Posted January 14, 2009 Share Posted January 14, 2009 Ah.. I also submitted this bug. My bug number is 1143. Sorry I didn't let you guys (who share the same problems) know.I have no knowledge of coding but I think the add to cart logic should be like this:1) if there is no combination --> add item to cart (regardless of stock status)2) if there are combinations --> take customer to product page and let them choose for their combination (don’t force to add something to cart or ajax cart regardless of stock status)This way customers experience will be smooth and it should be easy for coding too.Anyway, thanks for Presta Team for their effort. Since the bug was reported, let's sit back and wait for another release. Link to comment Share on other sites More sharing options...
chirameto Posted January 14, 2009 Share Posted January 14, 2009 Hey guys!! I just checked the SVN version (clean installation with sample data). And the problem gone!!I'll test with my own data again to make sure the problem has been cured. Link to comment Share on other sites More sharing options...
chirameto Posted January 15, 2009 Share Posted January 15, 2009 This problem has been fixed. I can confirm that the current SVN clean this problem. Thanks to presta team!!If you are in a hurry and don't wanna use SVN, just check out only /classes/Product.php and replace your 1.1 final file. Link to comment Share on other sites More sharing options...
Lircky Posted January 21, 2009 Share Posted January 21, 2009 wow it;s fixed, but i don't understand how to fix it?!SVN, what is it? where kan i find it?And how exactly kan i fix this problem, hope that somebody can give me a clear anwser.many THX Link to comment Share on other sites More sharing options...
ingenium Posted February 6, 2009 Share Posted February 6, 2009 I replaced Product.php with the version from subversion, and it corrects the problem, however now all pages are blank whenever a user is logged in. So this fix really isn't a fix.Lircky, you can just go to http://svn.prestashop.com/trunk/ and navigate it via your browser instead of using subversion.Edit: I've been able to fix the bug by disabling ajax, but I also had to unfortunately disable the security token or else I would get errors about hack attempts when adding an item to the cart. Link to comment Share on other sites More sharing options...
shutzu Posted February 27, 2009 Share Posted February 27, 2009 still now news about this? Link to comment Share on other sites More sharing options...
zippoutlet Posted March 24, 2009 Share Posted March 24, 2009 Already put a new post abt this matter...there are many stores working with the ajax cart...what is the solution for it?!?Rgds,E.Silva Link to comment Share on other sites More sharing options...
botc Posted May 11, 2009 Share Posted May 11, 2009 I also have this problem. If someone has a real fix, please post it in here Thanks Link to comment Share on other sites More sharing options...
john.e.perkin Posted September 30, 2009 Share Posted September 30, 2009 I found that if you update your site map, your google product feed and basically refresh all your modules, it clears up. Link to comment Share on other sites More sharing options...
t-prod Posted October 1, 2009 Share Posted October 1, 2009 Hi,I have also this problem in version 1.2.4. Although I make the correct CHMOD in all directories, it doesn't works.Blank page is still alive If I turn off ajax cart the problem is the same.I'm gonna try in a different hosting.Anything else ?Best regards Link to comment Share on other sites More sharing options...
Recommended Posts