修改 C:\Windows\System32\inetsrv\config\applicationHost.config 和网站的 Web.Config

<add name="php_FastCgiModule" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="D:\Work\YSGPT\Server\PHP\php-cgi.exe" resourceType="Either" responseBufferLimit="0"/>

注意增加 responseBufferLimit="0"


修改 php.ini

output_buffering = Off


在PHP代码中启用无缓存输出

<?php
// 10 minutes
set_time_limit(10000);

header('Cache-Control: no-cache');
header('Connection: keep-alive');
header('X-Accel-Buffering: no');

// Chrome 浏览器必须先收到一些数据,才能立即显示到页面
echo str_pad(' ', 1050);
flush();
// ...



本文链接地址: IIS+PHP流式无缓存输出
https://blog.qingfengju.com/index.asp?id=452

分类:Web开发 查看次数:953 发布时间:2024/4/17 12:12:06

安装 PHP Tools for Visual Studio 2022 v1.68.16373

安装 Xdebug https://xdebug.org/wizard


下面是断点调试的关键步骤:

选择 Don't open a page. Wait for a request from an external application

如果还不能停在断点处,在URL后面加上参数:XDEBUG_SESSION_START=TRUE



本文链接地址: 在Visual Studio 2022 中调试PHP
https://blog.qingfengju.com/index.asp?id=451

分类:Web开发 查看次数:755 发布时间:2024/4/16 22:10:05