Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2008-11-07 14:09:21

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Clean URLs on Debian Etch

I can’t get clean urls working at all on Debian Etch. in /etc/apache2/httpd.conf, I’ve put:

<Directory /var/www> AllowOverride FileInfo
</Directory>

And my .htaccess file looks like:

#DirectoryIndex index.php index.html

#Options +FollowSymLinks
#Options -Indexes

<IfModule mod_rewrite.c>
	RewriteEngine On
	#RewriteBase /relative/web/path/

	RewriteCond %{REQUEST_FILENAME} -f [OR]
	RewriteCond %{REQUEST_FILENAME} -d
	RewriteRule ^(.+) - [PT,L]

	RewriteRule ^(.*) index.php

	RewriteCond %{HTTP:Authorization}  !^$
	RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
</IfModule>

#php_value register_globals 0

Anyone know how to solve this issue?

Thanks

Last edited by ruud (2008-11-08 10:52:56)

Offline

#2 2008-11-07 15:33:45

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: Clean URLs on Debian Etch

Did you enable mod_rewrite in Apache? You should be able to do this with the following command on the console (command line):

aenmod rewrite

more info

Last edited by ruud (2008-11-07 15:39:27)

Offline

#3 2008-11-07 16:02:41

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Re: Clean URLs on Debian Etch

I forgot to mention that I did enable that mod

Offline

#4 2008-11-07 16:08:54

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: Clean URLs on Debian Etch

Then remove the <IfModule mod_rewrite.c> and </IfModule> parts and check if you get errors.

Offline

#5 2008-11-07 16:32:07

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Re: Clean URLs on Debian Etch

I commented out those two lines and there doesn’t appear to be any change

Offline

#6 2008-11-07 17:11:25

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: Clean URLs on Debian Etch

Daniel

Some possibilities…

  1. Are you using virtual hosts? If so, is there anything in your <VirtualHost> section for that site turning off .htaccess overrides (ie. AllowOverride None anywhere?)
  2. Do you have a non-standard AccessFileName directive in your httpd.conf (or VirtualHost directive) such that the configuration file is no longer the default .htaccess but something else?

HTH

Last edited by net-carver (2008-11-07 17:23:05)


Steve

Offline

#7 2008-11-07 17:29:35

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Re: Clean URLs on Debian Etch

I don’t have VirtualHosts configured on apache. httpd.conf only contains

<Directory /var/www>
AllowOverride FileInfo
</Directory>

Last edited by dmarino (2008-11-07 17:30:18)

Offline

#8 2008-11-07 17:33:52

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: Clean URLs on Debian Etch

Daniel

Any AccessFileName directive in your apache2.conf file?


Steve

Offline

#9 2008-11-07 18:40:59

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Re: Clean URLs on Debian Etch

it’s set to look for .htaccess

Offline

#10 2008-11-07 18:54:07

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: Clean URLs on Debian Etch

Hmm, sorry Daniel, I’m stuck then. You could try asking in #apache on irc.freenode.net


Steve

Offline

#11 2008-11-10 14:24:13

dmarino
Member
From: Southern New Hampshire
Registered: 2007-06-15
Posts: 18
Website

Re: Clean URLs on Debian Etch

I figured it out…

I was editing the httpd.conf which I thought would recognize the AllowOverride edit… but apparently I needed to make the edit in/etc/apache2/sites-available/default.

Reference: http://www.forwardthinkingdesign.com/blog/drupal-clean-urls-debian-lamp-stack

Offline

#12 2008-11-10 14:32:25

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: Clean URLs on Debian Etch

Daniel

Thanks for letting us know. Glad you got it sorted out!


Steve

Offline

Board footer

Powered by FluxBB