DhruvPathak DhruvPathak - 2 months ago 18
PHP Question

CodeIgniter : Run a script from command line if the controller is inside a folder?

As stated here :

A page like :

can be run on the command line as :

php index.php myController myFunc myParam

My codeignitor set up has some folders to group the controllers, lets say like this :

myFolder -> myPageController
-> myAdminController

So, the url becomes :


How do I call the same thing on CLI ?
Something like :

php index.php "myFolder/myController" myFunc myParam

Does not seem to work.


You can try with :

php index.php myFolder myController myFunc myParam1 myParam2 ...