Windows user - need help don't understand the command-line instructions
Posted 05 April 2011 - 07:19 PM
Posted 05 April 2011 - 10:55 PM
You can follow as :
E:\xampp\php>php.exe E:/xampp/htdocs/yii/framework/yiic webapp E:/xampp/htdocs/blog
where, E: is my drive location where I have installed xampp and blog is the web-application that I am creating.
Posted 06 April 2011 - 07:45 PM
Why didn't the author include Windows commands in addition to the Linux commands? It wouldn't have been that hard to do or add many more pages to the book! It's frustrating...
Posted 07 April 2011 - 01:58 AM
first thing you need to do is to put in the PATH the folder where your PHP.EXE is... so that you can run php from any folder without typing the full path... (don't ask how )
After that you need to understand what is a document root of your web server - if you don't understand this than you cannot really understand any command
Once you are in a webroot all the commands are relative to it... regardless if in the book is written % or some path like "C:\web\www" (just an example)
Posted 07 April 2011 - 03:24 PM
If using XAMPP in Windows Vista, do this:
Open the Environment Variables window by going to: Start -> Computer (right click) -> Properties -> Advanced System Settings (in the left sidebar) -> Click the "Advanced" tab in the window that pops up -> Click on "Environment Variables" -> In the "System variables" dialog box scroll down until you see "path" -> highlight it and click "Edit" -> In the "Variable Value" field go all the way to the very end and add a semi-colon, then add the full path to the folder that houses your php.exe file C:/xampp/php -> Add another semi-colon and then add the full path to yii's "framework" folder. For me, that was C:/xampp/htdocs/yii/framework -> You do not need a semi-colon after the final entry.
What does this do? It enables you go to your webroot directory and simply type
yiic webapp foldername
..instead of including full paths like Coda's example above. So one can use either method - the long way of typing out paths, or the short method after configuring your Windows PATH variable as explained above.
This information is customized for the XAMPP environment. If you are using WAMP, these instructions are for you:
(although the method for getting to the "Environment Variables" window is vague and wrong for Vista. Use my instruction above instead.)