"No input file specified" 将 PHP 与符号链接一起使用时
"No input file specified" when using PHP with symlink
我已经使用 ISPConfig 设置了一个网站。
在该网站根目录中我创建了符号链接test/ -> /var/test/
/var/test/
包含两个文件 - test.php 和 test.html。 test.html 工作正常,但是当我尝试 运行 test.php 我得到一个带有文本 No input file specified.
的白页
我的网站由 ISPConfig 运行ning Apache 2.2.22 自动配置。这是配置的摘录 - 请询问您是否需要查看更多内容:
<VirtualHost *:80>
<Directory /var/www/clients/client1/web2/web>
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<FilesMatch "\.ph(p3?|tml)$">
SetHandler None
</FilesMatch>
<Directory /var/www/clients/client1/web2/web>
AddHandler fcgid-script .php .php3 .php4 .php5
FCGIWrapper /var/www/php-fcgi-scripts/web2/.php-fcgi-starter .php
Options +ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
通过在 .htaccess
顶部设置 AddHandler application/x-httpd-php .php
解决
我已经使用 ISPConfig 设置了一个网站。
在该网站根目录中我创建了符号链接test/ -> /var/test/
/var/test/
包含两个文件 - test.php 和 test.html。 test.html 工作正常,但是当我尝试 运行 test.php 我得到一个带有文本 No input file specified.
我的网站由 ISPConfig 运行ning Apache 2.2.22 自动配置。这是配置的摘录 - 请询问您是否需要查看更多内容:
<VirtualHost *:80>
<Directory /var/www/clients/client1/web2/web>
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<FilesMatch "\.ph(p3?|tml)$">
SetHandler None
</FilesMatch>
<Directory /var/www/clients/client1/web2/web>
AddHandler fcgid-script .php .php3 .php4 .php5
FCGIWrapper /var/www/php-fcgi-scripts/web2/.php-fcgi-starter .php
Options +ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
通过在 .htaccess
顶部设置AddHandler application/x-httpd-php .php
解决