From f3dca8703690b18d91fc1bcbe6bbdb96704e90a5 Mon Sep 17 00:00:00 2001 From: Florent Bruneau Date: Fri, 21 Jan 2011 22:13:47 +0100 Subject: [PATCH] Don't serve static files through PHP. Signed-off-by: Florent Bruneau --- htdocs/css/bandeau.css | 18 ++++++++++-------- modules/bandeau.php | 1 + templates/skin/common.bandeau.head.tpl | 25 ------------------------- templates/skin/common.bandeau.tpl | 4 ++-- templates/skin/common.header.tpl | 1 + templates/skin/default.tpl | 1 - templates/skin/espace.tpl | 1 - templates/skin/humlinux.tpl | 1 - templates/skin/keynote.tpl | 1 - templates/skin/linux.tpl | 1 - templates/skin/liteskin.tpl | 1 - templates/skin/nbviolet.tpl | 1 - templates/skin/newxorg.tpl | 1 - templates/skin/oldtimes.tpl | 1 - templates/skin/openweb.tpl | 1 - templates/skin/register.tpl | 1 - templates/skin/sharky.tpl | 1 - templates/skin/spectral.tpl | 1 - templates/skin/trapped.tpl | 1 - templates/xnet/skin.tpl | 4 ++-- 20 files changed, 16 insertions(+), 51 deletions(-) delete mode 100644 templates/skin/common.bandeau.head.tpl diff --git a/htdocs/css/bandeau.css b/htdocs/css/bandeau.css index 2ccb3d8..8c2e225 100644 --- a/htdocs/css/bandeau.css +++ b/htdocs/css/bandeau.css @@ -18,11 +18,13 @@ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * ***************************************************************************/ -#bandeau-X a { vertical-align: middle; } -#bandeau-X a:link, #bandeau-X a:visited { text-decoration: none ; color: #505050; } -#bandeau-X a:hover { text-decoration: underline; color: black; } -#bandeau-X a:active { color: #CCCCCC ; background: #505050 ; } -body {margin:0px;} -#bandeau-X { -background:#CCCCCC;color:#505050;font-size:10px;font-family:Verdana, Arial, Helvetica, sans-serif;height:15px;border:none;padding:0;margin:0 } -#bandeau-X img { vertical-align:middle;border:0;padding:0;margin:0 } +@media screen { + #bandeau-X a { vertical-align: middle; } + #bandeau-X a:link, #bandeau-X a:visited { text-decoration: none ; color: #505050; } + #bandeau-X a:hover { text-decoration: underline; color: black; } + #bandeau-X a:active { color: #CCCCCC ; background: #505050 ; } + body {margin:0px;} + #bandeau-X { + background:#CCCCCC;color:#505050;font-size:10px;font-family:Verdana, Arial, Helvetica, sans-serif;height:15px;border:none;padding:0;margin:0 } + #bandeau-X img { vertical-align:middle;border:0;padding:0;margin:0 } +} diff --git a/modules/bandeau.php b/modules/bandeau.php index 09d0ad6..f5008c0 100644 --- a/modules/bandeau.php +++ b/modules/bandeau.php @@ -43,6 +43,7 @@ class BandeauModule extends PLModule $page->changeTpl('skin/common.bandeau.tpl', NO_SKIN); $page->assign('login', $login == 'login'); $page->assign('seed', $login); + $page->assign('external', true); } function handler_css(&$page) diff --git a/templates/skin/common.bandeau.head.tpl b/templates/skin/common.bandeau.head.tpl deleted file mode 100644 index 1846e97..0000000 --- a/templates/skin/common.bandeau.head.tpl +++ /dev/null @@ -1,25 +0,0 @@ -{**************************************************************************} -{* *} -{* Copyright (C) 2003-2011 Polytechnique.org *} -{* http://opensource.polytechnique.org/ *} -{* *} -{* This program is free software; you can redistribute it and/or modify *} -{* it under the terms of the GNU General Public License as published by *} -{* the Free Software Foundation; either version 2 of the License, or *} -{* (at your option) any later version. *} -{* *} -{* This program is distributed in the hope that it will be useful, *} -{* but WITHOUT ANY WARRANTY; without even the implied warranty of *} -{* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *} -{* GNU General Public License for more details. *} -{* *} -{* You should have received a copy of the GNU General Public License *} -{* along with this program; if not, write to the Free Software *} -{* Foundation, Inc., *} -{* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *} -{* *} -{**************************************************************************} - - - -{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *} diff --git a/templates/skin/common.bandeau.tpl b/templates/skin/common.bandeau.tpl index c904f1c..e790abd 100644 --- a/templates/skin/common.bandeau.tpl +++ b/templates/skin/common.bandeau.tpl @@ -24,7 +24,7 @@ incluez le fichier http://www.polytechnique.org/bandeau dans vos php ou http://www.polytechnique.org/bandeau/login pour profiter du login automatique. Et rajoutez à la liste de css de vos pages - http://www.polytechnique.org/bandeau.css. + http://www.polytechnique.org/css/bandeau.css. Pour avoir l'icone, pour des raisons de sécurité il n'y a pas d'accès direct, il faut alors rediriger bandeau/icone.png vers celle du site : http://www.polytechnique.org/bandeau/icone.png @@ -45,7 +45,7 @@
- + L'École · Institutional site ˜˜ diff --git a/templates/skin/common.header.tpl b/templates/skin/common.header.tpl index 5a38e88..fc1558f 100644 --- a/templates/skin/common.header.tpl +++ b/templates/skin/common.header.tpl @@ -29,6 +29,7 @@ + diff --git a/templates/skin/default.tpl b/templates/skin/default.tpl index 696dc7a..3b99315 100644 --- a/templates/skin/default.tpl +++ b/templates/skin/default.tpl @@ -23,7 +23,6 @@ {include file=skin/common.doctype.tpl} {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/espace.tpl b/templates/skin/espace.tpl index ea8d1f2..6e6bf9b 100644 --- a/templates/skin/espace.tpl +++ b/templates/skin/espace.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/humlinux.tpl b/templates/skin/humlinux.tpl index dac7c4d..3b4e58d 100644 --- a/templates/skin/humlinux.tpl +++ b/templates/skin/humlinux.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/keynote.tpl b/templates/skin/keynote.tpl index e31a983..1e473da 100644 --- a/templates/skin/keynote.tpl +++ b/templates/skin/keynote.tpl @@ -23,7 +23,6 @@ {include file=skin/common.doctype.tpl} {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/linux.tpl b/templates/skin/linux.tpl index c8b017f..6f3dfcc 100644 --- a/templates/skin/linux.tpl +++ b/templates/skin/linux.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/liteskin.tpl b/templates/skin/liteskin.tpl index dcbbad1..2d8231c 100644 --- a/templates/skin/liteskin.tpl +++ b/templates/skin/liteskin.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/nbviolet.tpl b/templates/skin/nbviolet.tpl index fc46d53..09f8ce2 100644 --- a/templates/skin/nbviolet.tpl +++ b/templates/skin/nbviolet.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/newxorg.tpl b/templates/skin/newxorg.tpl index 9dd40f8..bd2e552 100644 --- a/templates/skin/newxorg.tpl +++ b/templates/skin/newxorg.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/oldtimes.tpl b/templates/skin/oldtimes.tpl index 46b9abd..3077d5b 100644 --- a/templates/skin/oldtimes.tpl +++ b/templates/skin/oldtimes.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/openweb.tpl b/templates/skin/openweb.tpl index 519442e..aad38c6 100644 --- a/templates/skin/openweb.tpl +++ b/templates/skin/openweb.tpl @@ -23,7 +23,6 @@ {include file=skin/common.doctype.tpl} {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/register.tpl b/templates/skin/register.tpl index fa7acdb..047629e 100644 --- a/templates/skin/register.tpl +++ b/templates/skin/register.tpl @@ -23,7 +23,6 @@ {include file=skin/common.doctype.tpl} {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/sharky.tpl b/templates/skin/sharky.tpl index e8e18b8..a2fe7ea 100644 --- a/templates/skin/sharky.tpl +++ b/templates/skin/sharky.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/spectral.tpl b/templates/skin/spectral.tpl index be3b1c5..68752a1 100644 --- a/templates/skin/spectral.tpl +++ b/templates/skin/spectral.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/skin/trapped.tpl b/templates/skin/trapped.tpl index ce5db23..7c1f581 100644 --- a/templates/skin/trapped.tpl +++ b/templates/skin/trapped.tpl @@ -24,7 +24,6 @@ {include file=skin/common.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} diff --git a/templates/xnet/skin.tpl b/templates/xnet/skin.tpl index 6e67ba5..86a88ec 100644 --- a/templates/xnet/skin.tpl +++ b/templates/xnet/skin.tpl @@ -30,7 +30,8 @@ - + + @@ -40,7 +41,6 @@ {include core=plpage.header.tpl} - {include file=skin/common.bandeau.head.tpl} {include core=plpage.devel.tpl} -- 2.1.4