zoukankan      html  css  js  c++  java
  • vscode+php+xdebug won't stop at breakpoint 断点不起作用

    not stopping on breakpoints

    breakpoint not working

    原因:

    1) php.ini xdebug 端口不配置的情况下,默认是 9000,如果vscode里面改为了其他端口,php.ini里面也要改为同样的端口。

    如:

      a) vscode launch.json

    "configurations": [
            {
                "name": "Listen for XDebug",
                "type": "php",
                "request": "launch",
                "port": 9179,
                "stopOnEntry":true,
                "log": true
            },
            {
                "name": "Launch currently open script",
                "type": "php",
                "request": "launch",
                "program": "${file}",
                "cwd": "${fileDirname}",
                "port": 9179,
                "stopOnEntry": false,
                "log":true
            }
    

     php.ini 需要这么设置

    [XDebug]
    xdebug.profiler_append = 0
    xdebug.profiler_enable = 1
    xdebug.profiler_enable_trigger = 0
    xdebug.profiler_output_dir ="D:BtSoftWebSoft	empxdebug"
    xdebug.trace_output_dir ="D:BtSoftWebSoft	empxdebug"
    xdebug.profiler_output_name = "cache.out.%t-%s"
    xdebug.remote_enable = 1
    xdebug.remote_handler = "dbgp"
    xdebug.remote_host = "127.0.0.1"
    xdebug.remote_autostart = 1
    xdebug.remote_autorestart=1
    xdebug.remote_connect_back=1
    xdebug.remote_port=9179
    xdebug.remote_log = "D:BtSoftWebSoft	empxdebugdebug.log"
    zend_extension=php_xdebug.dll
    

    否则断点不起作用

  • 相关阅读:
    机器学习介绍
    Day03 作业
    Python函数基础
    Python练习
    耳机 线控 控制播放
    edittext 底线颜色
    从service启动activity startActivity慢 的解决方案
    国产手机没有google services 和google play崩溃,判断google services是否存在
    检测耳机插入和拔出
    获取view宽高
  • 原文地址:https://www.cnblogs.com/tyonly/p/vscode_xdebug_breakpoint_not_working.html
Copyright © 2011-2022 走看看