Magento 1.8.1 Javascript Undefined error when placing order

I just recently upgrade one of my magento ecommerce website from 1.7.x to 1.8.1 and one of my customer feedback that he encounter a javascript undefined error upon checkout.

After some comparison with the base folder of magento 1.8.1, i figured out that you need to amend the following page.

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

Search for the following line or similar

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

and change it to

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

Related posts

Magento – Get the list of products which customer wanted to be notify when it is back in stock

catalog_product index does not exist yet. Make sure everything is reindexed.

Unknown filter type [phonetic] for [phonetic]