2

使用 WAMP 3(Apache/2.4.23 (Win64) PHP/7.0.10 mod_fcgid/2.3.9 服务器在 localhost 端口 80)

# Virtual Hosts
#

<Directory c:/wamp/www/testdir>
    Options +Indexes +FollowSymLinks +Multiviews
    AllowOverride all
    Require local
</Directory>

<VirtualHost *:80>
    ServerAdmin <emailaddress>
    DocumentRoot "c:/wamp/www/testdir/"
    ServerName prerelease.mydomain.com
    DirectoryIndex index.php
    ErrorLog "logs/prerelease.mydomain.com-error.log"
    CustomLog "logs/prerelease.mydomain.com-access.log" common
</VirtualHost>
#

这是我的 httpd.conf (仅在标准文件末尾添加了这些行)

LoadModule fcgid_module modules/mod_fcgid.so

FcgidInitialEnv PHPRC "C:/wamp/bin/php/php7.0.10"
AddHandler fcgid-script .php
FcgidWrapper "C:/wamp/bin/php/php7.0.10/php-cgi.exe" .php

<IfModule fcgid_module>

    FcgidIOTimeout 1200
    FcgidConnectTimeout 1200
    FcgidBusyScanInterval 1200
    FcgidBusyTimeout 1200
    FcgidErrorScanInterval 1200
    FcgidIdleScanInterval 1200
    FcgidIdleTimeout 1200

    FcgidProcessLifeTime 3600
    FcgidZombieScanInterval 1200
    MaxRequestLen 15728640
    FcgidMaxRequestLen 15728640

</IfModule>

我必须在这里阅读了 20 多个线程并尝试了许多解决方案,但均无济于事。

以上所有方法都适用于 WAMP 的先前版本(Apache 2.4.9,PHP 5.5.12,相同的 mod_fcgid.so 文件)。

4

3 回答 3

0

可能的解决方案

改变

<Directory c:/wamp/www/testdir>
    Options +Indexes +FollowSymLinks +Multiviews
    AllowOverride all
    Require local
</Directory>

<Directory c:/wamp/www/testdir>
    Options +Indexes +FollowSymLinks +Multiviews
    AllowOverride all
    Allow from all
</Directory>

它应该允许每个人的连接。

并在它重新启动 APACHE 之后。

于 2016-10-28T17:25:31.963 回答
0

尝试安装 32 位版本。我了解您在技术上使用的是正确的版本,这只是我之前遇到的一个问题。它对我有用。

于 2016-10-28T17:33:55.293 回答
0

将“ExecCGI”添加到选项为我解决的问题:

<Directory / >
  Options Indexes FollowSymLinks ExecCGI
  # . . . . .
</Directory>
于 2019-08-09T17:41:24.837 回答