MyBB Community Forums

Full Version: htaccess rewrite url.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Greetings. I am trying to do so my portal.php is called home (without the .php)

Like from:
www.site.com/portal.php
to:
www.site.com/home

Is this possible somehow?


Also is it possible to do so:
www.site.com/page.php?id=rules
becomes:
www.site.com/rules
The .htaccess must have this at the top:
RewriteBase /

Also in Admin check: Configuration > Board Settings > Server and Optimization Options > Enable search engine friendly URLs?: Enabled
(2011-07-25, 07:02 PM)Puppyite Wrote: [ -> ]The .htaccess must have this at the top:
RewriteBase /

Also in Admin check: Configuration > Board Settings > Server and Optimization Options > Enable search engine friendly URLs?: Enabled

But with that code I can not do so www.site.com/portal.php is www.site.com/home
RewriteRule ^portal\.php$ home
RewriteRule ^page\.php?id=rules$ rules
(2011-07-26, 08:46 PM)Malcolm. Wrote: [ -> ]
RewriteRule ^portal\.php$ home
RewriteRule ^page\.php?id=rules$ rules

Thanks but when I put this into the htaccess file.
It doesn't show up the page.

I just get the 404 error page.
Both at www.site.com/portal.php and at www.site.com/home

Any idea?
I got it.

It just have to be like this:

RewriteBase /
RewriteRule home portal\.php