Welcome, Guest
Please Login or Register.
Lost Password?
Problem with htaccess (1 viewing)
Post Reply

TOPIC: Problem with htaccess

#15879
bhm8hwcm (User)
Posts: 19
graphgraph
Problem with htaccess 2008/08/24 21:18  
I am having a problem with htacces files. My sites do not seem to read them properly.

I am trying to use simple directives just to test things but does not work:
php_flag display_errors on
php_flag file_uploads of

One of my sites has mod_rewrite directives in htaccess and these seem to work but the above flags do not. Same with creating a new site...directives do not work.

Here is a sample of one of my configs:

<Directory /home/domain/public_html>
Options Indexes IncludesNOEXEC FollowSymLinks ExecCGI
allow from all
AllowOverride All
AddHandler fcgid-script .php
AddHandler fcgid-script .php5
FCGIWrapper /home/domain/fcgi-bin/php5.fcgi .php
FCGIWrapper /home/domain/fcgi-bin/php5.fcgi .php5
</Directory>

Any idea why it won't work or where I should look. I have restarted apache as well.
  The administrator has disabled public write access.
#15880
bhm8hwcm (User)
Posts: 19
graphgraph
Re:Problem with htaccess 2008/08/24 22:04  
Just did some testing.

I was able to get htaccess files to work but the php execution mode had to be Apache mod_php...I could not use CGIwrapper or FCGId.

I am confused about one thing though...not all directives can be controlled by htaccess.

If using mod_php then 'file_uploads' will always be set to on. I can not override with htaccess and also even if file uploads is set to off in the php settings, running phpinfo() will always show that fileuploads is on. If I change to CGIwrapper or FCGId then I can not override with httaccess (seems to not work) but I can override in the php settings.

How do the different execution modes handle these things?
  The administrator has disabled public write access.
#15894
ronald (User)
Posts: 511
graphgraph
Re:Problem with htaccess 2008/08/25 04:43  
running in mod_fcgid means you need to edit your php.ini which each domain has. /home/domain/etc instead of .htaccess

if you run in mod_php then you need to use .htaccess although some directives through the .htaccess will also work in mod_fcgid
  The administrator has disabled public write access.
#16858
ronnikc (User)
Posts: 10
graphgraph
Re:Problem with htaccess 2008/10/04 10:17  
Actually .htaccess works fine under CGIwrapper here.

However the last upgrade of VM Pro seems to have changed the default to FCGId instead so suddenly i found new sites with .htaccess failing to work - Then changed back to CGIwrapper and all was working as intended again.
  The administrator has disabled public write access.
Post Reply
get the latest posts directly to your desktop

Talk and Get Help

Support
Forums
Bugs and Issues

Get Virtualmin

OS Support
Buy Online
Download
Copyright 2005-2007 Virtualmin, Inc. All rights reserved.