Regex 重定向剩余字符串

Regex 重定向剩余字符串,regex,mod-rewrite,Regex,Mod Rewrite,我可以清理我的域名上的所有重定向,但最后一个仍然存在 example.com/?thtml 在这里,我根本不知道如何摆脱它。最糟糕的是,它是在搜索结果的第一个结果为几个关键字。 网站显示正确,但搜索结果仅显示中文/日文符号,而不是描述 图标????????????- example.com/?thtml-翻译此网站 什么时候开始 ... 您可以在下面看到已使用的.htaccess cose <ifModule mod_gzip.c> mod_gzip_on Yes mod_gzi

我可以清理我的域名上的所有重定向,但最后一个仍然存在

example.com/?thtml

在这里,我根本不知道如何摆脱它。最糟糕的是,它是在搜索结果的第一个结果为几个关键字。 网站显示正确,但搜索结果仅显示中文/日文符号,而不是描述

图标????????????-
example.com/?thtml-翻译此网站
什么时候开始 ...

您可以在下面看到已使用的.htaccess cose

<ifModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</ifModule>

## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"
</IfModule>
## EXPIRES CACHING ##

<IfModule mod_deflate.c>
    <filesMatch "\.(js|css|html|php|jpg|jpeg)$">
        SetOutputFilter DEFLATE
    </filesMatch>
</IfModule>

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^prodotti http://www.example.com/? [L,NC,R=301]
RewriteRule ^hosting http://www.example.com/? [L,NC,R=301]
RewriteRule ^housing http://www.example.com/? [L,NC,R=301]
RewriteRule ^assistenza http://www.example.com/? [L,NC,R=301]
RewriteRule ^nomeitalia.net http://www.example.com/? [L,NC,R=301]
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

mod_gzip_on Yes
是的
mod|gzip|item|u include file.(html?| txt | css | js | php | pl)$
mod_gzip_item_包含处理程序^cgi脚本$
mod_gzip_项目包括mime^text/*
mod_gzip_item_包括mime^application/x-javascript*
mod_gzip_项_排除mime^image/*
mod_gzip_item_排除rspheader^内容编码:.*gzip*
##过期缓存##
过期于
过期按类型映像/jpg“访问1年”
过期按类型图像/jpeg“访问1年”
ExpiresByType image/gif“访问1年”
过期按类型图像/png“访问1年”
ExpiresByType文本/css“访问1个月”
ExpiresByType text/html“访问1个月”
过期按类型应用程序/pdf“访问1个月”
ExpiresByType文本/x-javascript“访问1个月”
过期按类型应用程序/x-shockwave-flash“访问1个月”
过期按类型图像/x图标“访问1年”
ExpiresDefault“访问1个月”
##过期缓存##
SetOutputFilter放气
#开始WordPress
重新启动发动机
重写基/
重写规则^prodottihttp://www.example.com/? [L,NC,R=301]
重写规则^hostinghttp://www.example.com/? [L,NC,R=301]
住房http://www.example.com/? [L,NC,R=301]
重写规则^assistenzahttp://www.example.com/? [L,NC,R=301]
重写规则^nomeitalia.nethttp://www.example.com/? [L,NC,R=301]
重写规则^index\.php$-[L]
重写cond%{REQUEST_FILENAME}-F
重写cond%{REQUEST_FILENAME}-D
重写规则/index.php[L]
#结束WordPress
所以已经添加了一些重接线,将旧目录和内容重定向到主页,但最后的残余让我抓狂。也许你们中的一个可以告诉我怎么摆脱它


亲爱的凯伦,我问了两次同样的问题。。。或者至少答案是一样的

当我检查我之前的问题时,我发现我可以用第二个问题中的解决方案来解决这个问题。所以,我认为,这个问题要么被删除,要么至少以同样的方式回答

-在这里给出了两种可能的解决方案,其中第一种在这里也非常有效

斯塔基恩写道: 试试这个:

RewriteEngine On
RewriteCond %{THE_REQUEST} /\?([^\s]+) [NC] 
RewriteRule ^$ http://domain.com/? [NC,R,L]

参考:


-同样的问题我问了两次。。。或者至少答案是一样的

当我检查我之前的问题时,我发现我可以用第二个问题中的解决方案来解决这个问题。所以,我认为,这个问题要么被删除,要么至少以同样的方式回答

-在这里给出了两种可能的解决方案,其中第一种在这里也非常有效

斯塔基恩写道: 试试这个:

RewriteEngine On
RewriteCond %{THE_REQUEST} /\?([^\s]+) [NC] 
RewriteRule ^$ http://domain.com/? [NC,R,L]

参考:

-