Iam trying to rewrite my URL http://givehands.co.in/post.php?p=post&id=1
to http://givehands.co.in/post/1/
using htacess.
But it gets redirected to the URL http://givehands.co.in/post.php?p=post&id=1
instead of rewriting it? My domain givehands is mapped to a sub directory of my webserver.
Could any one help me out with the correct rewrite rule? Iam new to this.
Options -Multiviews
RewriteEngine On # Turn on the rewriting engine
RewriteBase /
RewriteCond %{REQUEST_URI} post/(.*)
RewriteRule post/(.*)/ http://givehands.co.in/post.php?p=post&id=$1 [L]
RewriteCond %{REQUEST_URI} post/
RewriteRule post/ http://givehands.co.in/post.php [L]
[L,R]
when you should have only[L]