PhpStorm+Xampp+Xdebug配置
来源:互联网 发布:淘宝客服每日工作总结 编辑:程序博客网 时间:2024/05/16 09:54
一、Xampp安装及配置
首先安装好xampp(个人安装文件在D:\Xampp)。
1.配置工作空间
打开文件 D:\Xampp\apache\conf\httpd.conf 更改属性DocumentRoot 后的参数至自己的工作空间(“D:/workspace/Php”),以后项目就放在这个文件夹里。
2.配置XDebug
Windows 环境下:
打开 D:\Xampp\php\php.ini 添加
[XDebug]
zend_extension = “D:\Xampp\php\ext\php_xdebug.dll”
xdebug.profiler_append = 0
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = “D:\Xampp\tmp”
xdebug.profiler_output_name = “cachegrind.out.%t-%s”
xdebug.remote_enable = on
xdebug.remote_handler = “dbgp”
xdebug.remote_host = “127.0.0.1”
xdebug.trace_output_dir = “D:\Xampp·\tmp”
xdebug.remote_port = 9000
重启 Apache
如果是Linux 需要下载 xdebug
http://code.activestate.com/komodo/remotedebugging/
解压后找到合适版本的xdebug.so并将其复制到/opt/lampp/lib/php/extensions/中。然后修改/opt/lampp/etc/php.ini文件,
在其最后加上
[XDebug]
zend_extension=”/opt/lampp/lib/php/extensions/xdebug.so”
xdebug.remote_enable=true
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000
xdebug.remote_handler=dbgp
xdebug.profiler_enable=1
xdebug.profiler_output_dir=”/opt/lampp/tmp”
lampp restart
2 PhpStorm
2.1 进入File>Settings>PHP>Servers,添加一个 Server
Name : localhost
Host : localhost
Port : 80
Debugger : Xdebuger2.2 进入File>Settings>PHP>Debug
Debug port : 90002.3 打开 Edit Configurations
添加一个 PHP Web Application
运行时 就用这个 Web 运行调试,搞定。
还不行就试试修改 上图中的Defaults,我把 server都改成了自己的localhost ,浏览器改成了firefox。
成果就是设置好断点,debug 运行,或者直接 shift + F9 则会自动打开火狐浏览器并且停留在断点处。
- 配置 Phpstorm + Xdebug + xampp
- PhpStorm+Xampp+Xdebug配置
- PhpStorm+Xampp+Xdebug配置
- xampp+phpStorm+Xdebug
- XAMPP+phpStorm+XDebug+Chrome
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome 配置和断点调试
- 本地环境 XAMPP+phpStorm+XDebug+chrome配置和断点调试
- Mac下PHP-XAMPP-PhpStorm-Xdebug断点调试配置
- Phpstorm+xdebug+xdebug help配置
- PHPStorm下XDebug配置
- Xdebug+phpstorm配置
- PHPStorm下XDebug配置
- PHPStorm下XDebug配置
- 自定义标签基本原理及作用
- React+Babel+Webpack初学者全家桶完整实例Demo
- 多线程-定时删除指定的带内容目录
- Hadoop运行jar包jdk版本冲突问题解决
- Codeforces Round #376 (Div. 2) D. 80-th Level Archeology —— 差分法 + 线段扫描法
- PhpStorm+Xampp+Xdebug配置
- 博客连接
- unity3d防止材质贴图丢失解决办法
- java中enum的用法总结
- 提交已有项目到GitHub
- 多线程-多线程常见的面试题
- 有十个台阶,一步或两步走,上楼梯有几种上法?
- 对象的赋值与对象的复制
- Centos 7 安装 Jenkins