开发者

Using .htaccess with FastCGI

I've reade开发者_如何学Pythond that when using FastCGI to run PHP the .htaccess file included into the main directory of my site is ignored (right now i have the .htaccess file located in /var/www/vhosts/mydomain.com/httpdocs) My question is how can i apply the directives and flags currently on .htaccess to this domain only? can i have an httpd.conf only for this domain? where should i put the current .htaccess content to keep the same settings working?

many thanks in advance,


Apache will read .htaccess files as long as AllowOverride is enabled in httpd.conf. What you cannot do is put PHP directives inside .htaccess: this works only with PHP installed as an Apache module and would cause a 500 Server error with PHP installed as either CGI or FastCGI.

Some configurations (with suphp and similar) allow for a per-directory php.ini with local settings. If this doesn't work with your setup you can change php.ini settings only with a series of ini_set() instructions (in an included file, most often)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜