Mod Rewirte Question.
Posted
by
delimit
on Stack Overflow
See other posts from Stack Overflow
or by delimit
Published on 2010-12-27T22:51:12Z
Indexed on
2010/12/27
22:53 UTC
Read the original article
Hit count: 214
mod-rewrite
I cant seem to get Example 1 to turn into Example 2 using mod rewrite. Can someone help me out?
Example 1
http://www.example.com/info/index.php?uid=123
Example 2
http://www.example.com/123
Mod rewrite code.
Options +FollowSymLinks
Options -Indexes
RewriteEngine on
RewriteBase /info
RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
RewriteRule ^(.*)$ http://www.example.com/info/$1 [R=301,L]
RewriteRule ^([^/]*)$ /info/index.php?uid=$1 [L]
© Stack Overflow or respective owner