ctrlsoluciones.com Posted November 13, 2009 Share Posted November 13, 2009 Hi guys, to see if anyone can help me ...In a single page of a product, defaults can be chosenamount to add to the basket, but on the main page (index.php) no,only see a button "Add to Cart"Is there any way that also in the index, each have its product displayedbox to enter a number of products to add to the basket? (thiswithout clicking on the product and go to the product page and then putamount)Thanks in advance!A greetingsorry for my english, im from spain! Link to comment Share on other sites More sharing options...
ningu Posted November 13, 2009 Share Posted November 13, 2009 With a search in the forum, you will have found : here ;-) Link to comment Share on other sites More sharing options...
ctrlsoluciones.com Posted November 13, 2009 Author Share Posted November 13, 2009 I can't do it for index.php page!Thanks! Link to comment Share on other sites More sharing options...
ningu Posted November 13, 2009 Share Posted November 13, 2009 It should be possible to do the same modification in file :module/homefeature/homefeature.tpl=> you will have it on homepage Link to comment Share on other sites More sharing options...
ctrlsoluciones.com Posted November 13, 2009 Author Share Posted November 13, 2009 my homefeatured.tpl {if $allow_buy_when_out_of_stock OR ($product.quantity AND $product.quantity > 0) OR $product.allow_oosp} {l s='Quantity :'} <input type="text" name="ajax_qty_to_add_to_cart[{$product.id_product|intval}]" id="quantity_wanted_{$product.id_product|intval}" class="text" value="{if isset($quantityBackup)}{$quantityBackup|intval}{else}1{/if}" size="2" maxlength="3" /> {l s='Add to cart'} {else} .my ajax-cart.js var idProduct = $(this).attr('rel').replace('ajax_id_product_', ''); ajaxCart.add(idProduct, null, false, this, $(’#quantity_wanted_’+idProduct).val()); return false; but no rulz :Scan you help me?Thanks! Link to comment Share on other sites More sharing options...
ningu Posted November 13, 2009 Share Posted November 13, 2009 In the following code : $(’#quantity_wanted_’+idProduct).val() you should use character ' (quote) instead of ` (backquote)Maybe this is the forum which as replaced them.With this modification, it works fine for meDon't forget to reload the index page to force the javascript to be reloaded Link to comment Share on other sites More sharing options...
ctrlsoluciones.com Posted November 13, 2009 Author Share Posted November 13, 2009 In the following code :$(’#quantity_wanted_’+idProduct).val() you should use character ' (quote) instead of ` (backquote)Maybe this is the forum which as replaced them.With this modification, it works fine for meDon't forget to reload the index page to force the javascript to be reloaded Thanks you very much!!You are god! Link to comment Share on other sites More sharing options...
Recommended Posts