Pentru a redirectiona tot traficul din HTTP catre HTTPS cu WWW:
- Se deschide FileManager in cPanel sau se face conexiune FTP.
- Se intra in folderul public_html
- Se deschide fisierul .htaccess sau se creaza daca nu exista
- Se va introduce :
-
# Inceput - Redirectionare to WWW - HTTPS RewriteCond %{HTTP_HOST} !^www\. [NC] RewriteRule ^ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301] RewriteCond %{HTTP:X-Forwarded-Proto} !https RewriteCond %{HTTPS} off RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] # Sfarsit - Redirectionare to WWW - HTTPS
6. Se salveaza.
Acum websiteul dvs. va face redirect pe https://www pentru toate paginile din acesta.