.htaccess将/ amp /网址重定向到非amp版本 [英] .htaccess redirect /amp/ urls to nonamp version
本文介绍了.htaccess将/ amp /网址重定向到非amp版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要在关闭Google AMP后恢复AMP Urls。您可以帮我将任何AMP网址上的301重定向回NonAMP版本吗?
I need to recover AMP Urls after switching off Google AMP. Can you help me please for having 301 redirects on any AMP url back to NonAMP Version?
示例:
anydomain/hardware/heute-ist-putztag/amp
返回
anydomain/hardware/heute-ist-putztag
推荐答案
自己找到解决方案
RewriteRule ^(.*)\/amp$ $1 [R=301,L]
这篇关于.htaccess将/ amp /网址重定向到非amp版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文