rewrite rule in htaccess

  • Answered
HI: I would like to prettify my url from to My htaccess file show the following codes: suPHP_ConfigPath /home/myusername/public_html Options +FollowSymlinks RewriteEngine on order allow,deny deny from all # and if filename extension with .php is appended is good KEEP the 2 lines RewriteCond %{REQUEST_FILENAME}.php -f RewriteRule (.+) /$1.php #from RewriteRule ^([^/]*)/([^/]*)\.html$ /view_recipe?id=$1&page=$2 [L] # this last line should prettify my urls and it does not. # I have tried numerous combinations without any success. The htacess file does not render any error and does not change the urls Hope you can help me to resolve this request. thank you
Hello, Thank you for your question on configuring your htaccess file to give you pretty URLs. Are you using a CMS? These (such as Joomla, WordPress, etc) usually have a setting to enable pretty URLs without you having to custom code your own. If not, the best we can do is to guide you to our article on how to create redirects in the htaccess file. We cannot provide custom coded solutions, unfortunately. Kindest Regards, Scott M