I have upgrade magento to 1.9.3.

I am facing the following error in the console in product page.

TypeError: Product.OptionsPrice is not a constructor

var optionsPrice = new Product.OptionsPrice([]);

It's caused by your custom theme not adding the new product_options.js file.

Edit your theme layout file (either local.xml or catalog.xml) and add the following under the <catalog_product_view> handle (or whatever page handle you're having the problem on):

<action method="addJs"><script>varien/product_options.js</script></action>
  • 6
    To fix this issue on category listing page also add the js under catalog_category_default handle – Tahir Yasin Oct 18 '16 at 22:27
  • 2
    This JS is added in the 3 page layout handles, so make sure to add it under all these layout handles catalog_product_view , catalog_product_send , catalog_product_compare_index in catalog.xml inside your theme layout folder if this JS is found missing – Haijerome Feb 15 '17 at 5:19
  • Same issue i had faced when i upgrade Magento version 1.8.1 to – Sourav Feb 3 '18 at 4:06
  • 1
    @Raphael at Digital Pianism why you don't use <reference name="head">? – LucScu Mar 8 '18 at 15:58

protected by Community Nov 17 '16 at 17:17

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

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