1) When i open new CMD (Win+R => cmd). It
I think you should try this out ! I had the same issue and solved it like this :
ok type : cd\windows\system32 After that you will see this: System32/: Type what you want (ex:ipconfig): System32: ipconfig Then that should do it ! :)
The problem is that some program has been set to autorun when you run cmd.exe. In my case it was ANSICON that was installed... and then I moved the file without properly uninstalling.
I found a solution in this blog post:
http://carol-nichols.com/2011/03/17/the-system-cannot-find-the-path-specified/
The short version is to find
HKCU\Software\Microsoft\Command Processor\AutoRun
and clear the value.
This actually looks like a startup error with PHP, not with your code. Does
php -r "echo 1;"
also throw the same error? If so, your php.ini file or an include may be pathed incorrectly.
php -i
should give you more info.