From faaa83b348c50093a93a66bb5d9bfa30284f7aa5 Mon Sep 17 00:00:00 2001 From: Fil <fil@rezo.net> Date: Fri, 9 May 2008 15:25:49 +0000 Subject: [PATCH] formfx.css, tire directement de http://www.alistapart.com/articles/prettyaccessibleforms , pour styler les formulaires du site public (conflit sans doute avec spip_style : il faudra faire des choix) --- .gitattributes | 1 + dist/formfx.css | 51 ++++++++++++++++++++++++++++++++++++++++++ dist/inc-head.html | 3 +++ ecrire/inc/filtres.php | 2 +- 4 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 dist/formfx.css diff --git a/.gitattributes b/.gitattributes index 6b04d0efe3..1cfdfaa53f 100644 --- a/.gitattributes +++ b/.gitattributes @@ -7,6 +7,7 @@ dist/feed.png -text dist/fond/ajax.html -text dist/fond/ajax_fonctions.php -text dist/fond/ajax_stat.html -text +dist/formfx.css -text dist/formulaires/choix_mots.html -text dist/formulaires/editer_article.html -text dist/formulaires/editer_article.php -text diff --git a/dist/formfx.css b/dist/formfx.css new file mode 100644 index 0000000000..7af9be3049 --- /dev/null +++ b/dist/formfx.css @@ -0,0 +1,51 @@ +/* + * + * Style des formulaires .formfx + * Inspire de http://www.alistapart.com/articles/prettyaccessibleforms + * "Prettier Accessible Forms", by Nick Rigby + * + */ +.formfx form fieldset { + margin-bottom: 10px; +} +.formfx form legend { + padding: 0 2px; + font-weight: bold; +} +.formfx form label { + display: inline-block; + line-height: 1.8; + vertical-align: top; +} +.formfx form fieldset ol { + margin: 0; + padding: 0; +} +.formfx form fieldset li { + list-style: none; + padding: 5px; + margin: 0; +} +.formfx form fieldset fieldset { + border: none; + margin: 3px 0 0; +} +.formfx form fieldset fieldset legend { + padding: 0 0 5px; + font-weight: normal; +} +.formfx form fieldset fieldset label { + display: block; + width: auto; +} +.formfx form em { + font-weight: bold; + font-style: normal; + color: #f00; +} +.formfx form label { + width: 120px; /* Width of labels */ +} +.formfx form fieldset fieldset label { + margin-left: 123px; /* Width plus 3 (html space) */ +} \ No newline at end of file diff --git a/dist/inc-head.html b/dist/inc-head.html index 81dffbb9d1..e4dba80a1a 100644 --- a/dist/inc-head.html +++ b/dist/inc-head.html @@ -23,6 +23,9 @@ [(#REM) Feuille de style CSS pour l'impression ] [<link rel="stylesheet" href="(#CHEMIN{impression.css}|direction_css)" type="text/css" media="print" />] +[(#REM) Feuille de style CSS pour les formulaires ] +[<link rel="stylesheet" href="(#CHEMIN{formfx.css}|direction_css)" type="text/css" media="all" />] + [(#REM) Feuille de style personnalisee pour surcharger les precedentes A noter par defaut cette css n'existe pas ] diff --git a/ecrire/inc/filtres.php b/ecrire/inc/filtres.php index d91db25e2c..073843ee81 100644 --- a/ecrire/inc/filtres.php +++ b/ecrire/inc/filtres.php @@ -2313,7 +2313,7 @@ function filtre_cache_static($scripts,$type='js'){ $dir = sous_repertoire(_DIR_VAR,'cache-'.$type); $nom = $dir . md5(serialize($scripts)) . ".$type"; if ( - $GLOBALS['var_mode']=='recalcul' + _request('var_mode') OR !file_exists($nom)){ $fichier = ""; $comms = array(); -- GitLab