I got a problem using Magento about add to cart with custom options.

I filled up all required fields and when I hit "Add To Cart" button, It said

Please specify the product required option(s).

When I go to other products without custom options like Size or Color field. It works fine.

How can I fix this problem?

this is the link: https://francesandalbert.com/ring.html


  • Options are not submitted (what is not really the case if you ask me), id is wrong (5), value is wrong (7), or there are more options on the products which might not be visible in frontend? Commented Mar 11, 2014 at 7:27

2 Answers 2


I don't know exactly how you can solve this but I can explain the problem, maybe it helps.

I see that the product page is on https but when you click on the add to cart button the form is submitted to http://francesandalbert.com/checkout/cart/add/uenc/aHR0cDovL2ZyYW5jZXNhbmRhbGJlcnQuY29tL3JpbmcuaHRtbD9fX19TSUQ9VQ,,/product/172/. Notice the http.

Then that pages does a 301 redirect to https://{same url} and what you send by post (the ring size) is lost.

If I use firebug and change the form url to https I can add the product to the cart without any problems.

You can try to change the submit url of the form Mage_Catalog_Block_Product_Abstract::getSubmitUrl or you can set the unsecure base url of your website to https://... avoiding 301 redirects from htaccess.

These are just my suggestions. I have no idea if they will work.

  • It works. Thank you so much Marius. I go to app/code/core/Mage/Catalog/Block/Product/View.php And I changed the getAddToCartUrl function from: return $this->helper('checkout/cart')->getAddUrl($product, $additional); to: $new_url = str_replace('http://','https://',$this->helper('checkout/cart')->getAddUrl($product, $additional)); return $new_url;
    – Enalds
    Commented Mar 11, 2014 at 8:42
  • @Enalds. I don't know if this is the cleanest solution but..."whatever floats your boat".
    – Marius
    Commented Mar 11, 2014 at 8:49
  • @Enalds change the unsecure url to https, your solution will bring you problems when you update! Commented Mar 11, 2014 at 9:33
  • @Fabian Blechschmidt - How can I change the unsecure url to https? I'm newbie to Magento :)
    – Enalds
    Commented Mar 12, 2014 at 5:44
  • 1
    I also add array('_secure' => true) to the <form action=...
    – Enalds
    Commented Mar 12, 2014 at 6:14

Check your ADD TO CART button code.

It should be:

<button type="button" title="<?php echo $buttonTitle ?>" class="button btn-cart" onclick="productAddToCartForm.submit(this)">
    <span><span><?php echo $buttonTitle ?></span></span>


app/design/frontend/default/<your theme name>/template/catalog/product/view and remove or rename addtocart.phtml.

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.