I need related products to have a quantity input on the view page and for the add to cart button to carry this quantity to the cart with the product.

Can anyone advise, thanks.

1 Answer 1


put below code in app/design/frontend/base/default/template/catalog/product/list/related.phtml

<?php if(!$_item->canConfigure() && $_item->isSaleable()): ?>
    <form  method="post"  id="event_form" action="<?php echo $this->helper('checkout/cart')->getAddUrl($_item) ?>" >
        <input id="qty" name="qty" type="text" value="1" >
        <button type="submit"><span><?php echo $this->__('Add to Cart') ?></span></button>
<?php endif; ?>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.