Answer the question
In order to leave comments, you need to log in
How to make a url like /article_name/page/?
There is a .htaccess file, redirects are configured in it.
To convert example.com/username?page=2 to example.com/profile.php?login=username&page=2 I use this rule:
RewriteRule ^([a-zA-Z0-9-]+)?page=([0-9]+)$ profile.php?login=$1&page=$2
Answer the question
In order to leave comments, you need to log in
Since when did GET become part of the url for mod_rewrite ?
# 301 --- test.ru/text/faq.html?faq=20 => test.ru/helpdesk/kb.php
RewriteCond %{QUERY_STRING} (^|&)faq=20($|&)
RewriteRule ^text/faq\.html$ /helpdesk/kb.php? [L,R=301]
RewriteCond %{QUERY_STRING} (^|&)faq=20($|&)
RewriteRule ^text/faq\.html$ /helpdesk/kb.php?&%{QUERY_STRING}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question