duane9322 2015-07-19 22:12
浏览 686

在cmd中运行php会拒绝访问并且“此应用程序无法在您的PC上运行”

I have installed xampp on my windows 8.1 and wanted to add PHP to environmental variables. Therefore, under path i added ;C:\xampp\php; in the end, like i have done some long time ago.

Now, when i try to run any php function in cmd, i get the windows message

"This app can't run on your PC.."

and a "Access is denied" in cmd.

If i remove php from the path variable, i still get the same error.

What i suspect could be a problem is that when trying to add the variable by typing SET PATH=%PATH% I accidentally clicked enter and therefore might have added an some weird value, although i have double checked and the whole line looks fine (no weird leftovers or something).

  • 写回答

2条回答 默认 最新

  • douwen8424 2016-09-27 06:53
    关注

    I had the same problem, I have tried a lot of things, but without success ... At the end of my efforts, I noticed that the size php.exe is 0KB , so I copy php.exe from my backup folder, where size is php.exe 75kB and php via cmd works

    评论

报告相同问题?

悬赏问题

  • ¥15 有人知道怎么将自己的迁移策略布到edgecloudsim上使用吗?
  • ¥15 错误 LNK2001 无法解析的外部符号
  • ¥50 安装pyaudiokits失败
  • ¥15 计组这些题应该咋做呀
  • ¥60 更换迈创SOL6M4AE卡的时候,驱动要重新装才能使用,怎么解决?
  • ¥15 让node服务器有自动加载文件的功能
  • ¥15 jmeter脚本回放有的是对的有的是错的
  • ¥15 r语言蛋白组学相关问题
  • ¥15 Python时间序列如何拟合疏系数模型
  • ¥15 求学软件的前人们指明方向🥺