Page 1 of 1

[FIXED] cmsms pretty urls not working

Posted: Sat Jul 21, 2007 6:08 pm
by sainsbury
Hi,

I have the following .htaccess file in my web directory:

Code: Select all

Options +FollowSymLinks
RewriteEngine on
RewriteBase /

# 301 Redirect all requests that don't contain a dot or trailing slash to
# include a trailing slash
RewriteCond %{REQUEST_URI} !/$
RewriteCond %{REQUEST_URI} !\.
RewriteRule ^(.*) %{REQUEST_URI}/ [R=301,L]

# Rewrites urls in the form of /parent/child/
# but only rewrites if the requested URL is not a file or directory
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteCond %{REQUEST_FILENAME} !-d [NC]
RewriteRule ^(.+)$ index.php?page=$1 [QSA]
(The standard one, basically).

But it seems to be being totally ignored by apache. All the correct httpd.conf settings have been applied to enable mod_rewrite but it does not work  :(

I did have it working, but then installed wordpress into a subdirectory which seemed to stop the pretty urls working (but could be totally unrelated). I have had this 'CMSMS with Wordpress in a subdirectory' work before but I've done something to stop this one working. Any thoughts?

Thanks,
Chris

Re: cmsms pretty urls not working

Posted: Sat Jul 21, 2007 6:10 pm
by sainsbury
PS I'm getting 404 file not found errors for, for example, /about/ or /home/

The index page does work, but no others.

Re: cmsms pretty urls not working

Posted: Sat Jul 21, 2007 6:51 pm
by SimonSchaufi
have you enabled it in the config.php?

Re: cmsms pretty urls not working

Posted: Sun Jul 22, 2007 9:49 am
by sainsbury
Yes I have - but to my knowledge the config.php simply changes the links on your site, whereas the .htaccess file actually makes them work. The links have been changed but do not work, hence a problem with .htaccess

Re: [FIXED] cmsms pretty urls not working

Posted: Sun Jul 22, 2007 10:04 am
by sainsbury
I've fixed this - AllowOverride was set to None in my Apache config (so it was obviously never working...)

Thanks anyway

Re: [FIXED] cmsms pretty urls not working

Posted: Mon Jul 30, 2007 2:32 pm
by Pierre M.
Hello Chris,
sainsbury wrote: I have the following .htaccess file in my web directory:
...
(The standard one, basically).
I'd like to stress that this is not the CMSms provided .htaccess sample (in the "doc" folder of the official package).
Pierre M.