1

I have this problem now:

Fatal error: Undefined class constant 'CHECK_USE_CHECKOUT' in /home/jwearfet/public_html/app/code/core/Mage/Checkout/Model/Type/Onepage.php on line 652

How to fix this problem?

Another problem, I just can not access to the payment page, just stay at "continue" process, how to solve this?

1
  • Hey Marius, Thanks for kind reply, what I did: 1, I edited the link that you sent to me to the my abstract.php; 2, Then copy whole payment folder under the local, bescause in under my local, there are only two folders: Catalog and Page, But after that the problem is still here..
    – Joyc
    Commented Aug 3, 2016 at 7:57

1 Answer 1

3

The line you mentioned looks like this:

$data['checks'] = Mage_Payment_Model_Method_Abstract::CHECK_USE_CHECKOUT

This means Magento cannot find the constant CHECK_USE_CHECKOUT in the class Mage_Payment_Model_Method_Abstract.
if your code is up to date, the constant should be there.

The constant was introduced in Magento 1.8.
The fact that this does not work for you makes me speculate, that at one point, you had an older version of magento (1.7 or below), you had to do some changes in the Mage_Payment_Model_Method_Abstract and you (or someone else) copied that class to app/code/local/Mage/Payment/Model/Method/Abstract.php.
Because of this, the class in the local folder is used and it's not up to date.
I suggest checking the differences between the class in the local folder and the core one from the version you previously had, copy the class from core to local (from the new version) and implement the changes in the new class.
Note: This is what can happen when you copy code to local code pool and you later upgrade.

2
  • I have had the very same issue, modified code from local code pool overriding the upgrades in core pool. Definitely worth checking. The two problems, this fatal error and not being able to access the payment page are probably related. Commented Aug 3, 2016 at 7:31
  • Hey Marius, Thanks for kind reply, what I did: 1, I edited the link that you sent to me to the my abstract.php; 2, Then copy whole payment folder under the local, bescause in under my local, there are only two folders: Catalog and Page, But after that the problem is still here..
    – Joyc
    Commented Aug 3, 2016 at 7:41

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.