Samples in admin are located as follows.
admin->controller->payment_xxx.php
admin->language->english->payment_xxx.php
admin->model->payments->model_admin_xxx.php
admin->template->default->content->payment_xxx.tpl
You will need to add the settings for this extension to be added as well. This is a sample for ccAvenue.
Code: Select all
# Extension ccAvenue
SET @lid=1;
SET @id=NULL;
SELECT @id:=extension_id FROM extension WHERE `controller` = 'payment_ccavenue';
INSERT INTO `extension` (`extension_id`, `code`, `type`, `directory`, `filename`, `controller`) VALUES (@id, 'ccavenue', 'payment', 'payment', 'ccavenue.php', 'payment_ccavenue') ON DUPLICATE KEY UPDATE extension_id=extension_id;
SET @id=NULL;
SELECT @id:=extension_id FROM extension WHERE `controller` = 'payment_ccavenue';
INSERT INTO `extension_description` (`extension_id`, `language_id`, `name`, `description`) VALUES (@id, @lid, 'ccAvenue', 'ccAvenue Gateway') ON DUPLICATE KEY UPDATE extension_id=extension_id;
Sample code as follows.
catalog->extension->payment->xxx.php
catalog->model->payment->model_payment.php You can either add code to this file or create a new one of your own.
If you have special, sensitive code required to process payments, this code would be better located in the library for better security.
library->payments->your_code.php
That's about all you usually need.