Apache Redirect

https://serverfault.com/questions/344614/simple-apache2-redirect-from-one-domain-to-another

https://www.digitalocean.com/community/questions/how-to-redirect-https-ip-to-https-domain

https://stackoverflow.com/questions/33874212/htaccess-redirect-https-to-another-https

You cannot match scheme http:// in RewriteCond %{HTTP_HOST}.
You can use this rule:
RewriteEngine On

RewriteCond %{HTTP_HOST} !^www\.domain\.com$ [NC]
RewriteRule ^ https://www.domain.com%{REQUEST_URI} [R=302,L]
You can use the RedirectPermanent directive to redirect the client to your new URL.
Just create a very simple VirtualHost for the old domain in which you redirect it to the new domain:
<VirtualHost *:80>
    ServerName xy.example.com
    RedirectPermanent / http://abc.example.com/
    # optionally add an AccessLog directive for
    # logging the requests and do some statistics
</VirtualHost>

Không có nhận xét nào:

Is it okay to use both fetchpriority="high" and loading="eager" in img tag?

 https://stackoverflow.com/questions/77744344/is-it-okay-to-use-both-fetchpriority-high-and-loading-eager-in-img-tag Yes Fetchpriority and l...