首页 > 系统相关 >PHP Windows 下 XAMPP 的 xdebug 配置

PHP Windows 下 XAMPP 的 xdebug 配置

时间:2023-05-08 16:38:09浏览次数:52  
标签:xampp remote IntelliJ Windows 配置 profiler xdebug PHP


在 IntelliJ 下调试 PHP 的断点有时候还是比较困惑的。

同时根据你使用的 xdebug 配置也有关系。

xdebug 2.x

下面的配置是 xdebug Version 2 的配置,如果你使用 xdebug 3.x 版本的话,配置是不同的。

[XDebug]zend_extension = "php_xdebug.dll"xdebug.remote_autostart = 1xdebug.profiler_append = 0xdebug.profiler_enable = 0xdebug.profiler_enable_trigger = 0xdebug.profiler_output_dir = "/xampp/tmp"xdebug.remote_enable = 1xdebug.remote_handler = "dbgp"xdebug.remote_host = "127.0.0.1"xdebug.remote_log = "/xampp/tmp/xdebug.txt"xdebug.remote_port = 9000xdebug.trace_output_dir = "/xampp/tmp"xdebug.remote_cookie_expire_time = 36000

xdebug 3.x

下面的配置是 xdebug 3.x 版本的配置,这个版本的配置已经有了不少的修改。

如果直接使用 xdebug 2.x 版本的配置的话,可能会遇到 IntelliJ 断点不停的问题。

[XDebug]zend_extension = "xdebug"xdebug.mode=debug
xdebug.client_host = 127.0.0.1xdebug.client_port = "9003"xdebug.start_with_request=yes



PHP Windows 下 XAMPP 的 xdebug 配置_php


改变

从 xdebug 3.x 开始,默认的调试端口使用了 9003 的端口,这个与 xdebug 2.x 使用的 9000 端口是不一样的。

这个需要注意。

另外:xdebug.start_with_request=yes 参数必须要添加,否则 IntelliJ 的断点不停。

官方的这篇文章:Configure Xdebug | IntelliJ IDEA Documentation 非常值得参考,最好仔细阅读下。

https://www.ossez.com/t/php-windows-xampp-xdebug/14334

标签:xampp,remote,IntelliJ,Windows,配置,profiler,xdebug,PHP
From: https://blog.51cto.com/cwikius/6254917

相关文章

  • PHP 高精度计算
    #两个高精度数比较#intbccomp(string$left_operand,string$right_operand[,int$scale])#$left=$right返回0#$left<$right返回-1#$left>$right返回1#$scale小数点位数#两个高精度数相加#stringbcadd(string$left_operand,string$right_o......
  • phpstorm导出导入设置
    导出设置到JAR文档要导出IDE设置到一个JAR文档在主菜单,选择File|ExportSettings在打开的ExportSettings对话框,指定要导出的设置项通过选择它们旁边的复选框。默认的,所有设置项都已选中。在Exportsettingsto文本框,为目标存档指定完全合适的名称。手动的输入路径或点击Browse......
  • 将windows操作系统(win10)装入移动硬盘
    1.准备windows系统镜像比如我的iso镜像:zh-cn_windows_10_business_editions_version_22h2_updated_april_2023_x64_dvd_c03ed5aa.iso镜像挂载后可以看到关键文件 2.对移动硬盘进行分区 listdiskselectdiskncleanconvertgptselectpartition1deletepartiti......
  • workerman下框架gateway报错 worker[thinkphp:30776] exit with status 64000
    wokerman启动之后一直报错Worker[30477]processterminatedworker[thinkphp:30477]exitwithstatus64000Worker[30533]processterminatedworker[thinkphp:30533]exitwithstatus64000Worker[30571]processterminatedworker[thinkphp:30571]exitwithstatus64......
  • Shortcut of Chrome on Windows & Linux
    ShortcutofChromeonWindows&LinuxTab&windowshortcutsActionShortcutOpenanewwindowCtrl+nOpenanewwindowinIncognitomodeCtrl+Shift+nOpenanewtab,andjumptoitCtrl+tReopenpreviouslyclosedtabsinthe......
  • Windows 安装 pycrypto 常见问题解决
    关于python使用Crypto.Cipher模块,ImportError:Nomodulenamed'Crypto' 常见问题解决1. 需要安装:MicrosoftVisualC++14.0error:MicrosoftVisualC++14.0isrequired.Getitwith"MicrosoftVisualC++BuildTools":http://landinghub.visualstudio.co......
  • Java 三方接口PHP写法;doHmacSHA2; 将字节数组转换成16进制字符串;Mac.getInstance;Hma
    先看一段Java代码,一个签名过程1packagecom.sixents.bss.filter;234importorg.apache.http.HttpEntity;5importorg.apache.http.NameValuePair;6importorg.apache.http.client.entity.UrlEncodedFormEntity;7importorg.apache.http.client.met......
  • php内容出现解决方法
    最近在写火车头插件时候,远程请求内容生成接口,内容会出现:&#xFEFF;转换成html就会有个换行,影响美观,于是找到解决办法。原因:出现这个问题的原因是在编辑文件的时候使用过utf8+bom的编码。第一个方法:找到执行文件将utf-8+bom的格式,修改为utf-8格式即可。第二个办法写个函数进行过......
  • windows游戏全屏的各种奇葩姿势
    1.改小系统分辨率,这会导致切出其他窗口时闪烁半天;AltEnter不管用,全屏后无视其他TopMost的窗口,Child内置窗口管用;若要全屏需关闭系统缩放否则全屏超出显示边界。ぜったい征服☆学園結社パニャニャンダー!!......
  • windows 右键菜单编辑/删除
    windows右键菜单编辑/删除。WIN7,WIN8,WIN10,WIN11。在https://www.sordum.org/7615/easy-context-menu-v1-6/页面底部下载软件,并解压出来。如果是64位系统,双击打开“EcMenu_x64.exe”。在菜单-文件-清理右键菜单。在不想要的菜单上,取消勾选,点刷新即可。-......