想要使用.htaccess替换.index.php?backLinks_free_Backlinks = 1& totalRows_free_Backlinks = 7 part by / backLinks_free_Backlinks / 1 from my url

时间:2012-07-18 16:39:59

标签: .htaccess

我的链接看起来像这样 http://backlinks.cheapratedomain.com/index.php?backLinks_free_Backlinks=1&totalRows_free_Backlinks=7

要使用.htaccess替换.index.php?backLinks_free_Backlinks = 1& totalRows_free_Backlinks = 7此部分/ backLinks_free_Backlinks / 1

替换链接后的

将会是这样的

http://backlinks.cheapratedomain.com/backLinks_free_Backlinks/1

1 个答案:

答案 0 :(得分:1)

尝试将此添加到文档根目录中的htaccess文件中:

RewriteEngine On
RewriteRule ^backLinks_free_Backlinks/([0-9]+)$ /index.php?backLinks_free_Backlinks=$1&totalRows_free_Backlinks=7 [L,QSA]

如果您不需要,可以从目标中删除&totalRows_free_Backlinks=7位。