410 生成 url 带参数
410 generated url with parameters
我有 url 类似这样的模式列表
https://www.web.com/?route=affiliate/register&
https://www.web.com/?route=account/edit&
https://www.web.com/index.php?route=affiliate/register&
https://www.web.com/index.php?route=account/edit&
https://www.web.com/?route=product/manufacturer/productmanufacturer_id
https://www.web.com/index.php?route=product/manufacturer/productmanufacturer_id
index.php
之后的任何 url 变体不再使用
我想寻求一些帮助以正确排序将 index.php
之后的任何内容设置为410,因为index.php仍在使用几个页面
---编辑---
我的默认索引页正在使用默认值 (index.php
,index.html
,index.htm
)
所以使用 ravi htaccess 代码这个 url 仍然是 return 200 OK(不起作用)
https://www.web.com/?route=affiliate/register&
https://www.web.com/?route=account/edit&
并且仅适用于此 url 变体
https://www.web.com/index.php?route=affiliate/register&
https://www.web.com/index.php?route=account/edit&
能否请您尝试按照所示示例编写。请在测试您的网址之前清除您的浏览器缓存。
RewriteEngine ON
RewriteCond %{QUERY_STRING} ^route [NC]
RewriteRule ^ - [R=410,L]
我有 url 类似这样的模式列表
https://www.web.com/?route=affiliate/register&
https://www.web.com/?route=account/edit&
https://www.web.com/index.php?route=affiliate/register&
https://www.web.com/index.php?route=account/edit&
https://www.web.com/?route=product/manufacturer/productmanufacturer_id
https://www.web.com/index.php?route=product/manufacturer/productmanufacturer_id
index.php
之后的任何 url 变体不再使用
我想寻求一些帮助以正确排序将 index.php
之后的任何内容设置为410,因为index.php仍在使用几个页面
---编辑---
我的默认索引页正在使用默认值 (index.php
,index.html
,index.htm
)
所以使用 ravi htaccess 代码这个 url 仍然是 return 200 OK(不起作用)
https://www.web.com/?route=affiliate/register&
https://www.web.com/?route=account/edit&
并且仅适用于此 url 变体
https://www.web.com/index.php?route=affiliate/register&
https://www.web.com/index.php?route=account/edit&
能否请您尝试按照所示示例编写。请在测试您的网址之前清除您的浏览器缓存。
RewriteEngine ON
RewriteCond %{QUERY_STRING} ^route [NC]
RewriteRule ^ - [R=410,L]