‘php.exe’ is not recognized as an internal or external command, operable program or batch file

前端 未结 10 1269
后悔当初
后悔当初 2020-11-29 08:24

‘php.exe’ is not recognized as an internal or external command, operable program or batch file.

Why does that error occur even though

10条回答
  •  春和景丽
    2020-11-29 08:30

    Set PHP as environment variable from System as below to run it from CMD

    1)Windows key + Pause
    2)Click on Advanced system settings
    3)Now click on Environment Variables.. button  
    4)In system variable section search for Path and edit it as D:\wamp\bin\php\php5.3.13;(If one needs to append it to some already exits value then start path with;)
    5)Now open CMD and run command PHP from any path where you don’t have PHP installed , in my case it’s C drive.
    6)We can check above set Path from CMD using Path command also.
    

提交回复
热议问题