0

I am using vscode to develop a theme for wordpress.
Inorder to debug, I've installed the vscode php debug extension and followed the instructions provided by the author of php debug to setup php debug environment in vscode.

However, my IIS server always return a page which indicates that the request has timeout at 2 ~ 3 minutes after I start to debug. I've already set the timeout of this website to 3600 seconds via IIS manager app and set max_execution_time = 3600 in php.ini, but it seems that these works all can't help.

What should I do to extend the timeout constraint of php debug environment in vscode?

Thanks for your suggestion.

The status of my computer is provided as follows:

Windows 7 ver 6.1 SP1 build 7601 IIS 7.5.7600.16385 php 7.2.3-nts-Win32-VC15-x64 php xdebug 2.7.2-7.2-vc15-nts-x86_64

vscode v1.33.1 vscode php debug v1.13

The debug settings of php project in vscode (launch.json):

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Listen for XDebug",
            "type": "php",
            "request": "launch",
            "port": 9000
        },
        {
            "name": "Launch currently open script",
            "type": "php",
            "request": "launch",
            "program": "${file}",
            "cwd": "${fileDirname}",
            "port": 9000
        }
    ]
}

The content of web.config for wordpress:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <system.webServer>
    <rewrite>
      <rules>
      <rule name="Main Rule" stopProcessing="true">
        <match url=".*"/>
          <conditions logicalGrouping="MatchAll">
            <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true"/>
            <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true"/>
          </conditions><action type="Rewrite" url="index.php"/>
      </rule>
            <rule name="WordPress: http://localhost" patternSyntax="Wildcard">
                <match url="*"/>
                    <conditions>
                        <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true"/>
                        <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true"/>
                    </conditions>
                <action type="Rewrite" url="index.php"/>
            </rule></rules>
    </rewrite>
    <defaultDocument>
      <files>
        <add value="index.php"/>
      </files>
    </defaultDocument>
  </system.webServer>
</configuration>

It seems that the first rule in web.config was inserted by Wordpress. Since the system run as usual with that rule, so I just left it there.

0

1 Answer 1

0

I just figure out what times out my request.
The FastCGI module has a time out setting as well and I did not configure it. Also noticed that the "activity timeout" should be extend as well, otherwise IIS will time out request.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .