-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating
Practical Module development for Prestashop 8
By :
Knowing our technical name (whreinsurance), we can now create our /modules/whreinsurance module folder. As explained in the previous chapter, we need to create a /modules/whreinsurance/whreinsurance.php file containing the module class definition, the /modules/whreinsurance/index.php file for security reasons, and the logo in the /modules/whreinsurance/logo.png file.
The /modules/whreinsurance/index.php file can be filled with the usual security content, as explained in the last chapter.
In the previous Hello World! module, we only defined a little text as an output sent to the hook. Now, we want to create a more elaborate module; that’s why we want to generate HTML via a Smarty template. We also want to use a style sheet to define the CSS styles.
Where do we store the CSS and the Smarty template files?
For all the view templates and assets (such as images, .css files, and .js files), we store them inside the views/...