Ayojewel Posted April 9, 2014 Share Posted April 9, 2014 (edited) Hello I am a newbie, and i need help urgently. I built a payment module to support a third party gateway, and it's showing in the back-end as installed, but on the payment page during checkout, it's not displayed as one of the payment options. My payment module contains the module.php, the payment.tpl and the payment return.tpl. Please what am i doing wrong? Or what haven't i done that i need to do? Am i missing some files? Any help will be appreciated, and following is a copy of my code: <?php if (!defined('_PS_VERSION_')) exit; class diamondwebpay extends Module { function __construct() { $this->name = 'diamondwebpay'; $this->tab = 'payments_gateways'; $this->version = 1.0; $this->author = 'Ayodeji Olumofe'; $this->ps_versions_compliancy = array('min' => '1.5', 'max' => '1.6'); parent::__construct(); // The parent construct is required for translations $this->page = basename(__FILE__, '.php'); $this->displayName = $this->l('diamondwebpay'); $this->description = $this->l('add diamondwebpay payment gateway to your shop'); } function install() { if (!parent::install()) return false; if (!$this->registerHook('payment') OR !$this->registerHook('paymentReturn')) return false; return true; } public function hookPaymentReturn($params) { if (!$this->active) return; global $smarty; $smarty->assign(array( 'status' => Tools::getValue('status', 'OPEN') )); return $this->display(__FILE__, 'payment_return.tpl'); } public function hookPayment($params) { if (!$this->active) return; global $smarty; $smarty->assign(array( 'this_path' => $this->_path, 'this_path_ssl' => Tools::getShopDomainSsl(true, true) . __PS_BASE_URI__ . 'modules/' . $this->name . '/', 'payment_methods' => $paymentMethods )); return $this->display(__FILE__, 'payment.tpl'); } } ?> Note: I have issue with my shop SSL Thanks Edited April 9, 2014 by Ayojewel (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts