visual studio code PHP debugging not working

前端 未结 6 782
清歌不尽
清歌不尽 2021-02-02 13:04

I have installed VS Code and the PHP debugger.

I am using xampp.

I tried running the code (2) ways (listen and launch).

6条回答
  •  时光说笑
    2021-02-02 13:21

    Add the following line in your lunch.json file :

    "runtimeExecutable": "c:\\xampp\\php\\php.exe"

    {
        "version": "0.2.0",
        "configurations": [
            {
                "name": "Listen for XDebug",
                "type": "php",
                "request": "launch",
                "port": 9000
            },
            {
                "name": "Launch currently open script",
                "type": "php",
                "request": "launch",
                "program": "${file}",
                "cwd": "${fileDirname}",
                "port": 9000,
                "runtimeExecutable": "C:\\Program Files\\PHP\\v7.3\\php.exe"
            }
        ]
    }
    

提交回复
热议问题