How to get mod rewrite to change an url's symbol for display purposes?
Good day all,
Ive been wondering, google searching and goign greyer quicker thinking if it is possible for mod rewrite to change a specific symbol it grabs from the url to something else?
i.e. if the url is www.website.com/foo-bar using the rewriterule I can get that hyphen to开发者_开发知识库 become a forward slash?
<?php $foobar = "foo-bar"; ?>
<a href="/<?php echo $foobar; ?>">foo-bar</a>
.htacces code I have..
RewriteRule ^([^/]+)$ index.php?page=$1 [L]
So basically I would like mod rewrite to make the url display on the addressbar as www.website.com/foo/bar if possible?
Regards,
Dan.
Have a look at this:
http://forum.modrewrite.com/viewtopic.php?t=2799
精彩评论