insert path after my domain with mod_rewrite

Discuss practical ways rearrange URLs using mod_rewrite.

insert path after my domain with mod_rewrite

Postby Farnaz » Tue Nov 30, 2004 11:18 pm

Hi,

I would like to add a path after my domain in url. For instance

change http://mydomain.com/login to http//mydomain.com/xyz/system/login

change http://mydomain.com/login/qqqq to http//mydomain.com/xyz/system/login/qqqq

I used rewrite rult in the following way:

RewriteRule ^/(.*)$ /xyz/system [R]

but with this rule, my related page can not be found.

Which changes should I make in This rule?

Regards,
Farnaz
Farnaz
 

Postby Redprince » Wed Dec 01, 2004 5:14 am

Code: Select all
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/([a-z0-9]*)$
RewriteRule ^(.*)$ /xyz/system/$1
Redprince
 
Posts: 5
Joined: Mon Nov 22, 2004 2:33 am
Location: Salzgitter, Lower Saxony, Germany


Return to Friendly URLs with Mod_Rewrite

Who is online

Users browsing this forum: No registered users and 34 guests

cron