hasta aqui la teoria pero en la practica se queda mudo no habla jejejej
aver si me podeis hechar una mano porfavor
Código PHP:
<?php
class websiteHttps {
var $https;
var $protocol;
var $host;
var $url;
function website_Https() {
global $website_https,$loggedInUser;
$this->https = $website_https;
$this->protocol = htmlentities($_SERVER["HTTPS"]);
$this->host = htmlentities($_SERVER["HTTP_HOST"]);
$this->url = htmlentities($_SERVER["REQUEST_URI"]);
if(!isUserLoggedIn()) { } else {
if ($this->https && isset($this->protocol)){
header('Strict-Transport-Security: max-age=500');
} elseif ($this->https && !isset($this->protocol)){
header('Status-Code: 301');
header('Location: https://'.$this->host.$this->url);
}
}
}
}
$websiteHttpsSec = new websiteHttps();
$websiteHttpsSec->website_Https();
?>
sin la clase funciona pero con ella todo junto no y no se que falla