Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 2 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th March 2008, 22:00
happz happz is offline
Senior Member
 
Join Date: Feb 2008
Location: Nashville, TN
Posts: 261
Thanks: 35
Thanked 6 Times in 5 Posts
Default centos 5.1 .htaccess not allowed

Can anyone tell me where to turn on the ability to use .htaccess with centos. I see some info on it else where but it has all been on os's other than centos.

thanks all....
happz!
Reply With Quote
Sponsored Links
  #2  
Old 20th March 2008, 10:37
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,419
Thanks: 812
Thanked 5,205 Times in 4,081 Posts
Default

.htaccess files are allowed on CentOS by Default. Please post the exact error message that you get in the error log of the website.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 23rd March 2008, 20:00
happz happz is offline
Senior Member
 
Join Date: Feb 2008
Location: Nashville, TN
Posts: 261
Thanks: 35
Thanked 6 Times in 5 Posts
Default not sure how to copy the contents of my error log but..

the error references the .htaccess file not being allow where it is. Where it is would be on the /web/.htaccess...which is where i needs to be but why or what do i need to do? Am i supposed to put the code in the ispconfig admin seciton of the site..under directives?..

update...here is the error message:
[Sun Mar 23 13:02:52 2008] [alert] [client 192.168.1.1] /var/www/web4/web/.htaccess: Options not allowed here
[Sun Mar 23 13:02:52 2008] [alert] [client 192.168.1.1] /var/www/web4/web/.htaccess: Options not allowed here

Last edited by happz; 23rd March 2008 at 20:05.
Reply With Quote
  #4  
Old 24th March 2008, 11:06
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,419
Thanks: 812
Thanked 5,205 Times in 4,081 Posts
Default

Either you put the code in the apache directives field of the site or you change the AllowOverride rule for all websites, which is defined at the end of your apache configuration file.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
happz (24th March 2008)
  #5  
Old 24th March 2008, 20:24
happz happz is offline
Senior Member
 
Join Date: Feb 2008
Location: Nashville, TN
Posts: 261
Thanks: 35
Thanked 6 Times in 5 Posts
Default Okay. I added to directives and that didn't do anything

This question is to anyone that knows or to Till...

I found the the apache config file and made the change yet problem is still there. i restarted apache also...here is the .htaccess file:

RewriteEngine On
Options +Followsymlinks
RewriteBase /
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.* - [L,QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^.*/images/(.*)$ /images/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^.*/uploads_user/(.*)$ /uploads_user/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/?$ /profile.php?user=$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/blog/([0-9]+)/?$ /blog_entry.php?user=$1&blogentry_id=$2 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/blog/([^/]+)?$ /blog.php?user=$1$2 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/blog/?$ /blog.php?user=$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/albums/([0-9]+)/([0-9]+)/?$ /album_file.php?user=$1&album_id=$2&media_id=$3 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/albums/([0-9]+)/?$ /album.php?user=$1&album_id=$2 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/albums/([0-9]+)/([^/]+)?$ /album.php?user=$1&album_id=$2$3 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/albums/?$ /albums.php?user=$1 [L]

with my VPS i would just drop this in the /www folder and it worked without a hitch. I am guessing the issue is with the / but not sure.

thanks!

Last edited by happz; 25th March 2008 at 03:43.
Reply With Quote
  #6  
Old 25th March 2008, 16:06
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,721 Times in 2,562 Posts
Default

Please add this to your Apache Directives field:

Code:
<Directory /var/www/web4/web>
AllowOverride All
</Directory>
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
The Following User Says Thank You to falko For This Useful Post:
happz (25th March 2008)
  #7  
Old 25th March 2008, 22:12
happz happz is offline
Senior Member
 
Join Date: Feb 2008
Location: Nashville, TN
Posts: 261
Thanks: 35
Thanked 6 Times in 5 Posts
Default the master! thanks falko!

Quote:
Originally Posted by falko
Please add this to your Apache Directives field:

Code:
<Directory /var/www/web4/web>
AllowOverride All
</Directory>
Yeap. Saved by falko again...

thanks!
Reply With Quote
  #8  
Old 20th July 2008, 01:19
happz happz is offline
Senior Member
 
Join Date: Feb 2008
Location: Nashville, TN
Posts: 261
Thanks: 35
Thanked 6 Times in 5 Posts
Default Question about this directives field add...

Quote:
Originally Posted by falko View Post
Please add this to your Apache Directives field:

Code:
<Directory /var/www/web4/web>
AllowOverride All
</Directory>

Falko or anyone...my question is can i add this directive to the hosting plan itself rather than to the specified site i.e. (/var/www/web4/web) but instead something like this but in the "hosting plan" section- /var/www/*/web

Anyone?


happz
Reply With Quote
  #9  
Old 20th July 2008, 11:11
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,419
Thanks: 812
Thanked 5,205 Times in 4,081 Posts
 
Default

If you want to set this for all sites, you can change the definitaion at the end of the apache2.conf file. But be aware that its a security risk to AllowOverride All for all sites and you should not do this if you host any third party sites for clients on your server.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting e-mail working hansoffate Installation/Configuration 29 13th August 2008 16:33
Tomcat on Centos 5.1 cybergal HOWTO-Related Questions 4 13th March 2008 11:02
Dspam Webui in Centos 5.1 davy Installation/Configuration 0 20th January 2008 02:51
CentOS and .htaccess rlhesson Installation/Configuration 5 31st March 2007 14:00
Ispconfig and Virtuemart shajazzi Installation/Configuration 7 21st February 2006 20:25


All times are GMT +2. The time now is 19:37.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.