Sito Lab Posted January 7, 2014 Share Posted January 7, 2014 hello, please I need to change the product page this function. Basically I would like that when the customer is on the product page and increase the amount of products (via the + and - buttons placed next to the quantity) the price will update automatically. Before posting I followed this guide http://www.prestashop.com/forums/topic/239317-change-quantity-with-buttons/ and everything works, but putting this $(document).ready(function(){ $("#quantity_wanted").change(function(){ $("#our_price_display").html(currencySign+" "+(productPrice*$("#quantity_wanted").val())); }); }); the price does not change, remains the same as I do? thanks Link to comment Share on other sites More sharing options...
Jan Jansen Posted February 11, 2014 Share Posted February 11, 2014 (edited) I got the same problem ! I'm trying to find a solution, but I'm not able to get it solved. I hope that Vekia can help us out or someone else. It must be doable, but I don't know anything about coding. Any input about this subject is more then welcome ! Thanks in advance. Edited February 11, 2014 by Jan Jansen (see edit history) Link to comment Share on other sites More sharing options...
PascalVG Posted February 11, 2014 Share Posted February 11, 2014 Hi Lui, Jan, can you: 1) add a link to your sites, to check if maybe default field names are renamed in the theme used and therefore the javascript isn't working 2) and mention which versions you use 3) Also check: if you add a different amount by just adding a new number in the amount/quantity input field and then click add to cart, does it work? (If not, then the method above will not work anyway) pascal Link to comment Share on other sites More sharing options...
Jan Jansen Posted February 11, 2014 Share Posted February 11, 2014 Hi Pascal, Thank you for your input! The provided code by lonlywolf got the job done for 50%, the other code was incomplete. 50% because everything works besides that most important thing!: the product price discounts are not calculated in the final price. And the product discounts were the only reason that I wanted this feature. Thanks again, if you have a solution please post it in the following topic: http://www.prestashop.com/forums/topic/239317-change-quantity-with-buttons/ Link to comment Share on other sites More sharing options...
PascalVG Posted February 12, 2014 Share Posted February 12, 2014 Hi Jan, can you add my IP address to your maintenance IP list, so can have a look in your shop tonight? You don't have to disable the maintenance mode then. IP: 183.88.253.22 pascal. Link to comment Share on other sites More sharing options...
PascalVG Posted February 12, 2014 Share Posted February 12, 2014 BTW, ziggo.nl klinkt erg Nederlands... :-) Link to comment Share on other sites More sharing options...
Jan Jansen Posted February 13, 2014 Share Posted February 13, 2014 Bedankt voor je interesse Pascal, Ik ben ook Nederlands Leuk land btw; Thailand. We zitten op het Engelstalige forumgedeelte, dus even verder in 't Engels: We (me and my companions) like to keep the shop private until our launch. The code of the product page is almost stock-code (product.tpl / product.js), so if you could provide us the (javascript?) code for the right pricing display calculation with the discounts caclulated, then that would be great ! Oftewel, we zouden dat zéér op prijsstellen !! Link to comment Share on other sites More sharing options...
Recommended Posts