How To Run PHP From Windows Command Line in WAMPServer

前端 未结 11 846
予麋鹿
予麋鹿 2020-11-22 04:58

I\'m new to php and wanted to run php from command line. I have installed WAMP and set the \"System Variables\" to my php folder ( which is C:\\wamp\\bin\\php\\php5.4.

11条回答
  •  没有蜡笔的小新
    2020-11-22 05:38

    Try using batch file

    1. Open notepad
    2. type php -S localhost:8000
    3. save file as .bat extension, server.bat
    4. now click on server.bat file your server is ready on http://localhost:8000

    Dependency

    if you got error php not recognize any internal or external command then goto environment variable and edit path to php.exe "C:\wamp\bin\php\php5.4.3"

提交回复
热议问题