第一步
安装phpStudy,下一步下一步...
安装好后运行,把fastadmin的项目文件放到localhost的默认网站目录里,然后根目录选到public下。
![](https://img.haomeiwen.com/i9566465/bb6cd68c996f23df.png)
选完确认就好了。
第二步
给php添加XDebug组件![](https://img.haomeiwen.com/i9566465/326db47799f1bd79.png)
![](https://img.haomeiwen.com/i9566465/c21c662d1379b3bd.png)
点完后会弹出记事本 拉到最后
![](https://img.haomeiwen.com/i9566465/b98323ab9bf45c2a.png)
[Xdebug]
zend_extension=C:/phpstudy_pro/Extensions/php/php7.2.9nts/ext/php_xdebug.dll
xdebug.trace_output_dir=C:/phpstudy_pro/Extensions/php_log/php7.2.9nts.xdebug.trace
xdebug.profiler_output_dir=C:/phpstudy_pro/Extensions/php_log/php7.2.9nts.xdebug.profiler
xdebug.profiler_append = 0
xdebug.profiler_enable=On
xdebug.profiler_enable_trigger = 0
xdebug.remote_enable=On
xdebug.remote_handler="dbgp"
xdebug.remote_mode = "req"
xdebug.remote_host=localhost
xdebug.remote_port=9002
xdebug.collect_params=1
xdebug.collect_return=1
xdebug.auto_trace=Off
设置伪静态
![](https://img.haomeiwen.com/i9566465/919bb06e8c6c04f0.png)
点开,改
server {
listen 80;
server_name localhost;
root "C:/phpstudy_pro/WWW/*******/public";#这里填你自己的
location / {
index index.html index.htm index.php;
#autoindex off;
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=/$1 last;
break;
}
}
location ~ \.php(.*)$ {
fastcgi_pass 127.0.0.1:9001;
fastcgi_index index.php;
fastcgi_split_path_info ^((?U).+\.php)(/?.+)$;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
include fastcgi_params;
}
}
这个是tp5的Nginx的伪静态设置
都设置完,phpstudy就好了重启服务就好了
第三步
安装浏览器插件。。。你自行百度 Xdebug helper
![](https://img.haomeiwen.com/i9566465/e4846f96e197b51b.png)
第四步
设置phpStorm
![](https://img.haomeiwen.com/i9566465/da8bc8547baf13cb.png)
保存。。。ok
这类教程太多了,不过都是要你设置service。。。
什么?不懂 ok! 点下面这个链接
https://www.cnblogs.com/gaowei521/p/10761885.html
网友评论