nitish062 Posted April 3, 2013 Share Posted April 3, 2013 Hi I am trying to develop a module "mymodule" from the prestashop developer guide tutorial.The code is below:( /modules/mymodule/mymodule.php) <?php if(!defined('_PS_VERSION_')) exit; class MyModule extends Module { public function __construct() { $this->name = 'mymodule'; $this->tab = 'Test'; $this->version = 1.0; $this->author = 'Nitish D'; $this->need_instance = 0; parent::__construct(); $this->displayName = $this->l('My Module'); $this->description = $this->l('Demo Decription'); public function install() { if(parent::install == false) return false; return true; } public function uninstall() { if(!parent::uninstall()) Db::getInstance->Execute('DELETE FROM ''._DB_PREFIX_.'mymodule''); parent::uninstall(); } } } ?> But it shows The following module(s) could not be loaded: mymodule (parse error in /modules/mymodule/mymodule.php) mymodule (class missing in /modules/mymodule/mymodule.php when I open modules from admin panel. I even converted the file to ASCII ( following the question http://www.prestasho...-class-missing/) but it still shows the error. Link to comment Share on other sites More sharing options...
prestashopninja Posted April 3, 2013 Share Posted April 3, 2013 (edited) Hi, Change class MyModule extends Module to class mymodule extends Module , using all lowercase. That should do it. Edited April 3, 2013 by prestashopninja (see edit history) Link to comment Share on other sites More sharing options...
nitish062 Posted April 3, 2013 Author Share Posted April 3, 2013 No sir, its same result I am getting i changed MyModule to mymodule Link to comment Share on other sites More sharing options...
prestashopninja Posted April 3, 2013 Share Posted April 3, 2013 Hi again, There were a few syntax errors in your code above. Please find the fixed verison attached. You can check for your mistakes comparing this one to yours. I hope this helps. mymodule.zip 4 Link to comment Share on other sites More sharing options...
nitish062 Posted April 3, 2013 Author Share Posted April 3, 2013 Thank you sir. i am able to install it. Link to comment Share on other sites More sharing options...
vekia Posted April 3, 2013 Share Posted April 3, 2013 so, it works now Now i can mark this topic as solved, right? Link to comment Share on other sites More sharing options...
trikiano Posted January 6, 2016 Share Posted January 6, 2016 je peut pas telecharger a cause de la restruction du Forum mm probleme Link to comment Share on other sites More sharing options...
Recommended Posts