Reputation: 535
I am trying to create a controller in cakephp(1.3) using console. I am using windows XP and XAMPP.
My current cake console settings below
C:\xampp\htdocs\cake\apressblog\cake\console>cake
♀ Welcome to CakePHP v1.3.4 Console --------------------------------------------------------------- Current Paths: -app: console -working: C:\xampp\htdocs\cake\apressblog\cake\console -root: C:\xampp\htdocs\cake\apressblog\cake -core: C:\xampp\htdocs\cake\apressblog
Changing Paths: your working path should be the same as your application path to change your path use the '-app' param. Example: -app relative/path/to/myapp or -app /absolute/path/to/myapp
Available Shells: acl [CORE]
i18n [CORE]api [CORE]
schema [CORE]bake [CORE]
testsuite [CORE]console [CORE]
To run a command, type 'cake shell_name [args]' To get help on a specific command, type 'cake shell_name help'
C:\xampp\htdocs\cake\apressblog\cake\console>-app c:\xampp '-app' is not recognized as an internal or external command, operable program or batch file.
C:\xampp\htdocs\cake\apressblog\cake\console>
what are the path settings I need to set for creating a controller from console ? I tried to change the app path but, when I type command cake It goes app directory to console,
Upvotes: 0
Views: 2336
Reputation: 9362
You can also run cake console without problems, provided you're at the correct path. Try the following:
C:\xampp\htdocs\cake\apressblog\>C:\xampp\htdocs\cake\apressblog\cake\console\cake
or, to save yourself the trouble, add C:\xampp\htdocs\cake\apressblog\cake\console
to the %PATH% environmental variable.
Upvotes: 0
Reputation: 521994
-app
is a parameter for the cake
command:
C:\...\console>cake -app C:\xampp\htdocs\cake\apressblog\app
Upvotes: 1