70 lines
3.4 KiB
PHP
70 lines
3.4 KiB
PHP
<?php header('Content-Type: text/html; charset=UTF-8'); ?>
|
|
|
|
<?php
|
|
|
|
header('X-Content-Type-Options: nosniff');
|
|
header('X-Frame-Options: SAMEORIGIN');
|
|
header('X-XSS-Protection: 1; mode=block');
|
|
header('Referrer-Policy: strict-origin-when-cross-origin');
|
|
|
|
?>
|
|
|
|
<!DOCTYPE html>
|
|
<html lang="it">
|
|
<head>
|
|
<title><?php echo $title_site; ?></title>
|
|
<meta name="description" content="<?php echo $description_site; ?>">
|
|
<meta name="application-name" content="<?php echo $title_site; ?>">
|
|
<link rel="icon" type="image/png" href="<?php echo $logo_site; ?>">
|
|
<meta charset="utf-8">
|
|
<meta name="msapplication-tap-highlight" content="no">
|
|
<meta name="HandheldFriendly" content="True">
|
|
<meta name="MobileOptimized" content="320"/>
|
|
<meta name="viewport" content="minimal-ui, width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
|
|
<meta name="robots" content="index, follow">
|
|
<meta name="mobile-web-app-capable" content="yes">
|
|
<meta name="application-name" content="<?php echo $title_site; ?>">
|
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
|
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
|
<meta name="apple-mobile-web-app-title" content="<?php echo $title_site; ?>">
|
|
<meta name="theme-color" content="#2a377e">
|
|
<meta name="apple-mobile-web-app-status-bar-style" content="#2a377e">
|
|
<meta name="screen-orientation" content="portrait">
|
|
<meta name="x5-orientation" content="portrait">
|
|
<meta name="x5-fullscreen" content="true">
|
|
<meta name="apple-mobile-web-app-orientations" content="portrait">
|
|
<meta name="browsermode" content="application">
|
|
<link rel="manifest" href="<?=$base_path?>/manifest.json?v=<?=$version_app?>">
|
|
<link rel="stylesheet" href="<?=$base_path?>/css/bootstrap.css">
|
|
<link rel="stylesheet" href="<?=$base_path?>/css/style.css?v=<?=$version_app?>">
|
|
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
|
<link rel="stylesheet" href="<?=$base_path?>/css/animation.css?v=<?=$version_app?>">
|
|
<script src="https://code.jquery.com/jquery-2.2.4.js"></script>
|
|
<script src="<?=$base_path?>/js/bootstrap.js"></script>
|
|
<script>
|
|
// Passa il percorso base a JavaScript
|
|
var BASE_PATH = "<?=$base_path?>";
|
|
|
|
// Forza l'orientamento portrait
|
|
if (window.screen && window.screen.orientation) {
|
|
// Tenta di bloccare l'orientamento in portrait
|
|
window.addEventListener('load', function() {
|
|
if (screen.orientation && screen.orientation.lock) {
|
|
screen.orientation.lock('portrait').catch(function(error) {
|
|
console.log('Orientation lock not supported or failed:', error);
|
|
});
|
|
}
|
|
});
|
|
}
|
|
|
|
// Fallback per dispositivi che non supportano l'API
|
|
// Mostra un avviso se l'utente ruota il dispositivo
|
|
window.addEventListener('orientationchange', function() {
|
|
if (window.orientation !== 0 && window.orientation !== 180) {
|
|
// Il dispositivo è in landscape, ma non possiamo forzarlo
|
|
console.log('Si prega di tenere il dispositivo in posizione verticale');
|
|
}
|
|
});
|
|
</script>
|
|
</head>
|
|
<body class="<?php echo $show_app ? 'appBody' : 'desktopBody'; ?>">
|