View previous topic :: View next topic |
Author |
Message |
ShadowMetis Apprentice

Joined: 03 Feb 2005 Posts: 181 Location: Newburgh, NY
|
Posted: Sat Mar 04, 2006 9:29 pm Post subject: Apache .htaccess Files Not Working |
|
|
I'm trying to make a certain directory where .phps files will be served as PHP files, however the .htaccess file isn't working. I have the AllowOverride directive properly set for the directory in which I'm trying to work with, however it's still not working.
Code: |
httpd.conf:
<Directory "/home/htdocs">
Options FollowSymlinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<Directory "/home/htdocs/images2">
Options FollowSymlinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
/home/htdocs/images2/.htaccess:
SetHandler application/x-httpd-php
| [/code] |
|
Back to top |
|
 |
s0be Apprentice


Joined: 23 Nov 2002 Posts: 240
|
Posted: Sat Mar 04, 2006 10:11 pm Post subject: |
|
|
Try wrapping your sethandler directive in a location or directory section.
Code: |
<Location path >
SetHandler ....
</Location>
|
edit: aha, found where i used it locally:
Code: |
<Location .>
SetHandler application/x-httpd-php
</Location>
|
|
|
Back to top |
|
 |
ShadowMetis Apprentice

Joined: 03 Feb 2005 Posts: 181 Location: Newburgh, NY
|
Posted: Sat Mar 04, 2006 10:52 pm Post subject: |
|
|
Like this?
Code: |
<Location "/images2">
SetHandler application/x-httpd-php
</Location>
|
|
|
Back to top |
|
 |
s0be Apprentice


Joined: 23 Nov 2002 Posts: 240
|
Posted: Sun Mar 05, 2006 2:38 am Post subject: |
|
|
ShadowMetis wrote: | Like this?
Code: |
<Location "/images2">
SetHandler application/x-httpd-php
</Location>
|
|
I don't think you need the quotes.
If you need to use a path with spaces in it, just escape them.
Code: | <Location /windows/Program\ Files> |
|
|
Back to top |
|
 |
|