Cho vào index php
Code:
$url = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
if (strtolower($url) != $url){
$link = "Location: " . strtolower($url);
header("HTTP/1.1 301 Moved Permanently");
header($link);
exit();
}