Example
You must add php to your path environment variable. Follow theses steps :
Windows 7 :
- Right-click on a My Computer icon
- Click Properties
- Click Advanced system settings from the left nav
- Click Advanced tab
- Click Environment Variables button
- In the System Variables section, select Path (case-insensitive) and click Edit button
- Add a semi-colon (;) to the end of the string, then add the full file system path of your PHP installation (e.g.
C:\Program Files\PHP
)
- Keep clicking OK etc until all dialog boxes have disappeared
- Close your command prompt and open it again
- Sorted
Windows 8 & 10
- In Search, search for and then select: System (Control Panel)
- Click the Advanced system settings link.
- Click Environment Variables.
- In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
- Add the full file system path of your PHP installation (e.g.
C:\Program Files\PHP
)
After this, open your command console and execute the following command:
c:\> php -r "readfile('https://symfony.com/installer');" > symfony
Then, move the downloaded symfony file to your project's directory and execute it as follows:
c:\> move symfony c:\projects
c:\projects\> php symfony