- Activarea redirectionarii permanente prin modificarea fisierului de configurare al virtual host
<VirtualHost *:80> ServerName www.lorand.work Redirect permanent / https://www.lorand.work/ </VirtualHost> <VirtualHost _default_:443> ServerName www.lorand.work DocumentRoot /var/www/httpdocs SSLEngine On </VirtualHost>
- Activarea redirectionarii folosind fisierul .htaccess
RewriteEngine On RewriteCond %{HTTPS} !=on RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
Leave a Reply