At Magento Onepage Checkout page nothing happens after clicking [Continue] button at Billing information step. It is not possible to proceed to Shipping, Magento checkout just stuck.
The following error logged in PHP error log:
PHP Fatal error: Call to undefined method Mage_Checkout_OnepageController::isFormkeyValidationOnCheckoutEnabled() in app/code/core/Mage/Checkout/controllers/OnepageController.php on line 374
Cause
SUPEE-9767v2 (and v1 as well) addedisFormkeyValidationOnCheckoutEnabled()
function into app/code/core/Mage/Core/Controller/Front/Action.php file:
diff --git app/code/core/Mage/Core/Controller/Front/Action.php app/code/core/Mage/Core/Controller/Front/Action.php index b6eac9e..4f96782 100644 --- app/code/core/Mage/Core/Controller/Front/Action.php +++ app/code/core/Mage/Core/Controller/Front/Action.php @@ -188,4 +188,14 @@ class Mage_Core_Controller_Front_Action extends Mage_Core_Controller_Varien_Acti { return Mage::getStoreConfigFlag(self::XML_CSRF_USE_FLAG_CONFIG_PATH); } + + /** + * Check if form_key validation enabled on checkout process + * + * @return bool + */ + protected function isFormkeyValidationOnCheckoutEnabled() + { + return Mage::getStoreConfigFlag('admin/security/validate_formkey_checkout'); + } }
Solution
As the error saysisFormkeyValidationOnCheckoutEnabled()
is undefined:
- check if SUPEE-9767v2 was applied properly and the function is defined in app/code/core/Mage/Core/Controller/Front/Action.php:
$ grep "function isFormkeyValidationOnCheckoutEnabled" app/code/core/Mage/Core/Controller/Front/Action.php protected function isFormkeyValidationOnCheckoutEnabled()
- Check for local overrides in app/code/local/Mage/Core/Controller/Front/Action.php and app/code/community/Mage/Core/Controller/Front/Action.php:
$ ls -la app/code/{local,community}/Mage/Core/Controller/Front/Action.php
and apply the changes from patch to local overrides as well - Disable Magento Compiler
If you have any difficulties with solving this problem or got a similar one, please let us know in comments below, so we can find the solution together.
Posted in: Fatal errors