From: Jerome Jutteau Date: Thu, 16 Jul 2015 09:31:41 +0000 (+0200) Subject: xhtml application when managed by server X-Git-Tag: 1.1~40 X-Git-Url: https://git.p6c8.net/jirafeau.git/commitdiff_plain/7736957442e464ad66415e458330b9da6c47ae23?hp=d36beb5721c5a2fbda02c947e6953a490fa6aac6 xhtml application when managed by server Signed-off-by: Jerome Jutteau --- diff --git a/lib/template/header.php b/lib/template/header.php index 91f857e..dd7ec3c 100644 --- a/lib/template/header.php +++ b/lib/template/header.php @@ -3,6 +3,9 @@ header('Vary: Accept'); $content_type = 'text/html; charset=utf-8'; +if (stristr ($_SERVER['HTTP_ACCEPT'], 'application/xhtml+xml')) + $content_type = 'application/xhtml+xml; charset=utf-8'; + header('Content-Type: ' . $content_type); $protocol = (bool)is_ssl() ? 'https' : 'http'; @@ -22,10 +25,22 @@ if (!isset ($cfg['style'])) else $style = $cfg['style']; - +if (stristr ($_SERVER['HTTP_ACCEPT'], 'application/xhtml+xml')) +{ +?> + + + + <?php echo t('Jirafeau, your web file repository'); ?>