JohnnyKennedy Posted February 19, 2012 Share Posted February 19, 2012 Hey guys! Here's hoping you can help me out, I'm new to the whole rewrite rule, but basically what I'm trying to do is tidy up my URLS and make them more search engine friendly - so, when a user navigates to ../view/book/essentials of economics, they are (behind the scenes) actually visiting ../view.php?book=essentials of economics. I've tried it every way possible, and have spent days researching it - but each time i try write it to .htaccess I get 500 internal errors? Any help would be greatly appreciated. Thanks Again. Link to comment https://forums.phpfreaks.com/topic/257308-change-viewphpbooktitleeconomics-url-to-viewbookeconomics/ Share on other sites More sharing options...
AyKay47 Posted February 19, 2012 Share Posted February 19, 2012 you will only need one rewrite rule for this. Something along the lines of: RewriteEngine On RewriteRule ^view/([a-z]+)/([a-z]+)$ view.php?$1=$2 [NC,L] Link to comment https://forums.phpfreaks.com/topic/257308-change-viewphpbooktitleeconomics-url-to-viewbookeconomics/#findComment-1318935 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.