Closed. This question is off-topic. It is not currently accepting answers.admin管理员组文章数量:1318564
Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 4 years ago.
Improve this questionAnyone who can guide me in this matter, I want to resolve the redirect chain?
- redirect to
- and then redirect to
.
I want to redirect directly from to
.
Redirection plugins in WordPress are not working, as they are only worked with to redirect pages or posts.
This is a redirection code in .htaccess.
# BEGIN rlrssslReallySimpleSSL rsssl_version[3.3.5]
<IfModule mod_rewrite.c>
RewriteEngine on RewriteCond %{HTTP:CF-Visitor} '"scheme":"http"'
RewriteCond %{REQUEST_URI} !wp-content\/cache\/(all|wpfc-mobile-cache)
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
# END rlrssslReallySimpleSSL
Closed. This question is off-topic. It is not currently accepting answers.
Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 4 years ago.
Improve this questionAnyone who can guide me in this matter, I want to resolve the redirect chain?
http://www.example
- redirect to
https://www.example
- and then redirect to
https://example
.
I want to redirect directly from http://www.example
to https://example
.
Redirection plugins in WordPress are not working, as they are only worked with to redirect pages or posts.
This is a redirection code in .htaccess.
# BEGIN rlrssslReallySimpleSSL rsssl_version[3.3.5]
<IfModule mod_rewrite.c>
RewriteEngine on RewriteCond %{HTTP:CF-Visitor} '"scheme":"http"'
RewriteCond %{REQUEST_URI} !wp-content\/cache\/(all|wpfc-mobile-cache)
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
# END rlrssslReallySimpleSSL
Share
Improve this question
edited Oct 20, 2020 at 12:23
Rup
4,4004 gold badges29 silver badges29 bronze badges
asked Oct 20, 2020 at 11:17
SubhanSubhan
11 bronze badge
12
|
Show 7 more comments
1 Answer
Reset to default 1RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
Replace %{HTTP_HOST}
with your canonical hostname. For example:
RewriteRule ^(.*)$ https://example/$1 [R=301,L]
You will need to clear your browser cache before testing.
本文标签: htaccessI want to resolve Redirect Chain
版权声明:本文标题:htaccess - I want to resolve Redirect Chain 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1742048318a2417924.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
.htaccess
file in order to retain formatting. (Comments are not for code dumps.) – MrWhite Commented Oct 20, 2020 at 12:11