this project it's useful to learn about how to manage files with php and do something like composer, but composer use the .phar php files, here i don't, You can use this or fork and edit for your project pattern.
- 📂 app
- 📂 controllers
- 📂 models
- 📂 views
-
The base folder have the files and the pattern code inside those files.
-
The generatormvc.bat file execute the generatormvc.php, then this file use your commands to create the MVC files.
-
The generatormvcscript.iss file it's a inno setup code used to create an executable file
Base command:
generatormvc <func> <type> <name>
generatormvc
: base command.
<func>
: what you want to do, so far it has only 2 commands:create
to create files anddelete
to delete files
<type>
: the type you want:mvc
to create all,controller
to create only a controller,model
to create only a model orview
to create a folder and a .html, .css and .js files
<name>
: the name you want for the files:
- 📂 app
- 📂 controllers
- 📄 controllerProduct.php
- 📂 models
- 📄 modelProduct.php
- 📂 views
- 📂 product
- 📄 product.html
- 📄 product.css
- 📄 product.js