php - 使用 WSL2 时 VSCode Php 调试器无法正常工作
问题描述
我已经在 Windows 10 上安装了 WSL2,设置了 LAMP 并安装了 php-xdebug。
在/etc/php/8.0/mods-available/xdebug.ini
我添加了这个:
zend_extension=xdebug.so
xdebug.remote_enable = 1
xdebug.remote_autostart = 1
xdebug.show_error_trace = 1
xdebug.remote_port=9000
之后我运行sudo service apache2 restart
命令。
然后在 VSCode 中添加断点,在 Chrome 上访问本地开发站点,它不起作用。它不会在断点处停止。
我以前在 WSL 上做这个已经 2 年多了,但现在我不知道为什么它不再起作用了......
有人有想法吗?
解决方案
推荐阅读
- three.js - 如何使用非平面形状(表面)的threejs绘制具有3d点(x,y,z)的形状几何
- node.js - 在节点 js Firestore 事务中读取多个文档
- javascript - 处理来自异步调用的数据
- qt - yocto-krogoth 中的 falkon 编译中的 cmake 错误
- c# - MongoDB 中的运算符使用官方 .NET 驱动程序执行多过滤器查询
- python - 无法连接到 pymssql
- linux - 如果充电器 = 未插电,请提醒我。命令行脚本
- performance-testing - 性能测试中的吞吐量计算
- ios - 滚动到 UITableView 底部时出现问题
- vba - 按主题另存为邮件项目