Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Tips and Tutorials
Modules Best practise and Oil
I am about to start a large project and would like advice on the best way to work with modules.
Is there any way to use oil to create controllers, models, migrations for modules?
Also is there a simple way to create a blank module with all the folders required?
Or do I create a fuel site for each module and copy the final folders to the main project?
A module has exactly the same structure, so if you copy the contents of the 'app' folder (of a new installation) to your module folder, you should have everything. You only need to remove the welcome stuff from it.
To generate into a module, you can use the "--module=modulename" commandline switch.
Thanks for your response!
I can't however get the commandline switch to work.
I have tried:
oil g --module=services controller test
oil g controller --module=services test
oil g controller test --module=services
I have checked the url /Services/Welcome is working so I know my module structure ok.
Also can I generate scaffolding inside the new module?
My mistake, after I checked the code it seems to be implemented for config, but not for anything else. Odd.
Maybe create a feature request for it, at
Add a Comment
It looks like you're new here. If you want to get involved, click one of these buttons!
Apply for Membership
↳ Job Board
↳ Installation & Setup
↳ Tips and Tutorials
↳ Code share
In this Discussion