Pretty URLs : how to remove /index.php/ ?
Posted: Sat May 27, 2006 5:40 pm
Hi,
I'll want to remove /index.php/ in my url, like this:
http://mysite.com/index.php/home/ will become http://mysite.com/home/, like on this site.
I'm using CMSMS 0.13 Final.
I try the Russ' method, but I've got a 500 Internal Server Error.
config.php :
htaccess :
(I have only this code in my htaccess file)
mod_rewrite work on my hosting (ovh.com), for example, the "no-www" code works fine.
If someone can help me... thanks 
I'll want to remove /index.php/ in my url, like this:
http://mysite.com/index.php/home/ will become http://mysite.com/home/, like on this site.
I'm using CMSMS 0.13 Final.
I try the Russ' method, but I've got a 500 Internal Server Error.
config.php :
Code: Select all
$config['assume_mod_rewrite'] = true;
$config['page_extension'] = '/';
$config['internal_pretty_urls'] = false;
$config['use_hierarchy'] = true;
Code: Select all
#Config for CMS
RewriteEngine On
# 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]
mod_rewrite work on my hosting (ovh.com), for example, the "no-www" code works fine.
Code: Select all
RewriteEngine On
RewriteCond %{HTTP_HOST} ^www\.domain\.com$ [NC]
RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L]
