Having hard time converting PhonePe payment gateway extension from OC 3.x to OC 4.x
Posted: Mon Jun 23, 2025 3:00 pm
1. Your Exact OpenCart Version - 4.1.0.3
2. Used Template/Theme - Custom.
3. (Additional) Installed Extension(s)
4. (Additional) Installed Translation(s)
5. Used php Version - 8.3
6. Used Browser and Version- chrome
7. Do you use cloudflare > No
I am trying to convert the PhonePe payment gateway extension, which was initially coded for OC version 3.x
https://www.opencart.com/index.php?rout ... ch=phonepe
I have done this so far -
/public_html/extension/phonepePG/
For the admin side controllers, my namespace is -
For the admin side model, my namespace is -
For the catalog side controllers, my namespace is -
The extension is named as phonepePG.ocmod.zip
The extension "installs" successfully, but the database tables, as mentioned in the model files, fail to create.
Also, index.php?route=extension/phonepePG/payment/phonepePG says - "The page you are looking for could not be found! Please contact your administrator if the problem persists."
This doesn't seem to have any effect.
Any help or pointers will be highly appreciated.
2. Used Template/Theme - Custom.
3. (Additional) Installed Extension(s)
4. (Additional) Installed Translation(s)
5. Used php Version - 8.3
6. Used Browser and Version- chrome
7. Do you use cloudflare > No
I am trying to convert the PhonePe payment gateway extension, which was initially coded for OC version 3.x
https://www.opencart.com/index.php?rout ... ch=phonepe
I have done this so far -
/public_html/extension/phonepePG/
Code: Select all
install.json
+---admin
| +---controller
| | \---payment
| | phonepePG.php
| |
| +---language
| | \---en-gb
| | \---payment
| | phonepePG.php
| |
| +---model
| | \---payment
| | phonepePG.php
| |
| \---view
| +---image
| | \---payment
| | 156pxv2.jpg
| | pay_Online.png
| | pay_Online_old.png
| |
| \---template
| \---payment
| phonepePG.twig
| phonepePG_order.twig
|
+---catalog
| +---controller
| | \---payment
| | phonepePG.php
| |
| +---language
| | \---en-gb
| | +---extension
| | \---payment
| | phonepePG.php
| |
| +---model
| | \---payment
| | phonepePG.php
| |
| \---view
| \---template
| \---payment
| phonepePG.twig
| phonepePGs.twig
| phonepePG_response.twig
|
\---system
\---library
\---phonepePG
ChecksumUtils.php
PhonepeConfig.php
TransactionUtils.php
For the admin side controllers, my namespace is -
Code: Select all
namespace Opencart\Admin\Controller\Extension\PhonepePG\Payment;
class PhonepePG extends \Opencart\System\Engine\Controller {
Code: Select all
namespace Opencart\Admin\Model\Extension\PhonepePG\Payment;
class PhonepePG extends \Opencart\System\Engine\Model {
Code: Select all
namespace Opencart\Catalog\Controller\Extension\phonepePG\Payment;
class PhonepePG extends \Opencart\System\Engine\Controller {
The extension "installs" successfully, but the database tables, as mentioned in the model files, fail to create.
Also, index.php?route=extension/phonepePG/payment/phonepePG says - "The page you are looking for could not be found! Please contact your administrator if the problem persists."
Code: Select all
$this->response->setOutput($this->load->view('extension/phonepePG/payment/phonepePG', $data));
Any help or pointers will be highly appreciated.