Reputation: 5461
I have a php class file, and I want to find out how I can run it on the Windows command line. Do I need to install something? Are there any tutorials? Any help will be greatly appreciated!
Upvotes: 1
Views: 3709
Reputation: 157
Open up the Command Line switch to the folder where your php class is located. then type the path to your php.exe and give the class file as parameter. Try googling for "Add PHP to Path" to get some information how to do this with like 'php file.class.php'
Hope this helps.
Upvotes: 0
Reputation: 4097
Install xampp and then read this:
http://www.blog.highub.com/php/running-php-using-windows-command-line-with-xampp/
Upvotes: -1
Reputation: 11106
Assuming you have PHP already installed for windows use this to run a file:
php.exe -f myfile.php
More detail here: http://php.net/manual/en/install.windows.commandline.php
Upvotes: 4