Magento – Magento Place order give undefined alert box

javascriptmagento-1.8onepage-checkout

Recently I have upgrade my Magento store from 1.3 to 1.8. I fixed almost errors. Now am facing a strange issue in the last step of the check out. When I click the place order button I get an undefined alert and nothing happens after that.

Somebody told me to alert transport.responseText on skin/design/frontend/package/theme/js/opcheckout.js to show the errors.

But I can't get any error in this alert. It just contains an html code of the check out page.

Anybody know what is the issue here.

Best Answer

app/design/frontend/default/YOUR_THEME/template/checkout/onepage/review/info.phtml

Find code

echo $this->getUrl('checkout/onepage/saveOrder');

Replace it with:

echo $this->getUrl('checkout/onepage/saveOrder', array('form_key' => Mage::getSingleton('core/session')->getFormKey()));

Make sure to take file backup

Related Topic