After recently installing opencart and configuring it for using PayPal or a homemade payments module I've written, whenever I reach the payment information page as a customer I see the error message "Error: Payment method required!".
I've been searching through the code to try and work out whats missing and from where but as far as I can see its all in place. I've got 2 payment methods enabled and permissions have been set correctly in User Groups. Any urgent assistance really appreciated.
I've been searching through the code to try and work out whats missing and from where but as far as I can see its all in place. I've got 2 payment methods enabled and permissions have been set correctly in User Groups. Any urgent assistance really appreciated.
Tracing through all the code to try and find the problem, I notice on line 48 of catalog/controller/checkout/payment.php that the $results array comes back empty after the following line:
Not sure why, dont think thats how it should be so looking further. Got a very tight deadline here so would really appreciate some community help. If I get this working I'll contribute a new payment module for Barclays.
-Richard
Code: Select all
$results = $this->model_checkout_extension->getExtensions('payment');
-Richard
If I run the SQL query it runs in /catalog/model/checkout/extension.php on line 4 outside of OpenCart then I get results for each payment method installed and enabled, and the returning array will hold the extension_id, type and key values for each record. Why do I get an empty array back from line 4? If the query is failing for some reason why don't I see an error message?
Line 4:
I've tried it without the $this->db->escape function and still no rows returned.
Line 4:
Code: Select all
$query = $this->db->query("SELECT * FROM extension WHERE `type` = '" . $this->db->escape($type) . "'");
Changing geo zone options doesn't seem to affect this issue at all. Thanks for the suggestion though.
After adding a simple logging mechanism to the MySQL class in /system/database/mysql.php it actually looks like the query is never being run - nor even the file being used perhaps?
So what actually happens between $results = $this->model_checkout_extension->getExtensions('payment'); being called in /catalog/controller/checkout/payment.php and the query never taking place?
Really getting confused here. Could really use the help of a developer who knows OpenCart inside out.
Thanks
So what actually happens between $results = $this->model_checkout_extension->getExtensions('payment'); being called in /catalog/controller/checkout/payment.php and the query never taking place?
Really getting confused here. Could really use the help of a developer who knows OpenCart inside out.
Thanks
Who is online
Users browsing this forum: Baidu [Spider] and 19 guests