php - 为 PHP 配置 Notepad++ DBGP 插件和 XDebug

标签 php plugins notepad++ xdebug

我遵循了这些步骤:

  1. 下载x-debug*.dll到D:\Program Files\webserver\php\ext\php_xdebug.dll
  2. 修改php.ini 并插入以下内容

    zend_extension_ts="D:\Program Files\webserver\php\ext\php_xdebug.dll"
    xdebug.remote_enable=1
    xdebug.remote_handler=dbgp
    xdebug.remote_mode=req
    xdebug.idekey=default
    xdebug.remote_autostart=1
    
  3. 重启 apache,XDebug 安装成功。

  4. DBGP安装成功并配置为127.0.0.1

但 XDebugger 仍然无法连接/使用 notepad++。

最佳答案

我在这里找到了答案

http://thecancerus.com/debugging-php-using-xdebug-and-notepad-part-i/

确保您安装了最新版本的 Notepad++。

  1. 下载 DBGp Plugin 的最新版本.
  2. 解压 dbgpPlugin.dll 文件并将其移动到 notepad++ 安装文件夹的 plugins 文件夹,在我的例子中路径是“C:Program FilesNotepad++plugins”。
  3. 查看与插件捆绑在一起的 readme.txt 文件,以确保我们没有遗漏任何内容。
  4. 现在打开 Notepad++,您应该会在插件菜单中看到 DBGp 选项。
  5. 我们现在几乎完成了设置,剩下的就是配置 DBGP 以监听正确的端口,我们就完成了。
  6. 转到“Plugins->DBGp->Config”以打开 DBGp 插件的配置屏幕。 enter image description here
  7. IDE KEY 应该与您在上面的 php.ini 设置中指定的相同。单击确定,您就完成了。
  8. 要开始调试,只需在您的网址末尾添加“?XDEBUG_SESSION_START=session_name”。 “session_name”可以是您想要保留的任何内容。

关于php - 为 PHP 配置 Notepad++ DBGP 插件和 XDebug,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5139469/

相关文章:

regex - 正则表达式替换多字节字符?

encoding - notepad++ 显示 ucs-2LE 而 ubuntu FILE [file] 显示 UTF-16LE,我很困惑?

PHP计数,每2个字符加冒号

php - 如何为我的网络用户创建一个 "todo"列表来勾选?

jquery - 使用 ('change' jQuery 插件设置选择标签样式时,在 "nice-select"上获取选择标签 .val() 不起作用

android - 如何仅在 cordova 4.0 的单个页面上覆盖后退按钮?

notepad++ - 使用全部替换在 GUID 中放置破折号

javascript - PHP中显示AJAX函数返回的多个值时出错

php - MySQL ID 未传递到下一页

javascript - 用于 CSS 和 JavaScript 的类似 CheckStyle 的 Eclipse 插件?