user6125 Tól től Ismeretlen Tagság dec. -0001 óta user6125 22 nov. 2018 18:56 I am trying to install a payment module from admin panel. i was expecting to see an added module from payment folder, but i had this srange error saying... Fatal error: Uncaught Error: Class 'pm_mymodule' not found in C:\Bitnami\wampp\apache2\htdocs\litecart-2.1.4\public_html\admin\modules.app\modules.inc.php:110 Stack trace: #0 C:\Bitnami\wampp\apache2\htdocs\litecart-2.1.4\public_html\admin\index.php(125): include() #1 {main} thrown in C:\Bitnami\wampp\apache2\htdocs\litecart-2.1.4\public_html\admin\modules.app\modules.inc.php on line 110. And i am running LiteCart version 2.1.4. help pls!!
tim Founder Tól től Sweden Tagság máj. 2013 óta tim 22 nov. 2018 20:16 Show your code for pm_mymodule.inc.php.
user6125 Tól től Ismeretlen Tagság dec. -0001 óta user6125 23 nov. 2018 07:30 public $id = __CLASS__; public $name = 'My Module'; public $description = 'Lorem ipsum dolor'; public $author = 'ACME Corp.'; public $version = '1.0'; public $website = 'http://www.litecart.net'; public $priority = 1; public function options($items, $subtotal, $tax, $currency_code, $customer) { return array( 'title' => 'My Payment module', 'options' => array( array( 'id' => 'method1', 'icon' => 'images/payment/mymodule-method1.png', 'name' => 'Method 1', 'description' => 'Select this option for method 1.', 'fields' => '', 'cost' => 0, 'tax_class_id' => 0, 'confirm' => 'Confirm Order', ), ) ); } public function pre_check($order) { } public function transfer($order) { } public function verify($order) { } public function after_process($order) { } public function receipt($order) { } function settings() { return array( array( 'key' => 'status', 'default_value' => '0', 'title' => 'Status', 'description' => 'Enables or disables the module.', 'function' => 'toggle("e/d")', ), array( 'key' => 'icon', 'default_value' => 'images/payment/'.__CLASS__.'.png', 'title' => 'Icon', 'description' => 'Web path of the icon to be displayed.', 'function' => 'input()', ), array( 'key' => 'order_status_id', 'default_value' => '0', 'title' => 'Order Status:', 'description' => 'Give successful orders made with this payment module the following order status.', 'function' => 'order_status()', ), array( 'key' => 'priority', 'default_value' => '0', 'title' => 'Priority', 'description' => 'Process this module in the given priority order.', 'function' => 'int()', ), ); } public function install() { } public function uninstall() { } }