From eabfb01982a46c170c48824e19a60eb721c2a281 Mon Sep 17 00:00:00 2001 From: James <james@rezo.net> Date: Mon, 11 Dec 2006 21:17:25 +0000 Subject: [PATCH] les echos de inc/minipres.php disparaissent. --- ecrire/action/pass.php | 4 +-- ecrire/exec/convert_utf8.php | 4 +-- ecrire/exec/export_all.php | 4 +-- ecrire/exec/upgrade.php | 4 +-- ecrire/inc/minipres.php | 66 +++++++++++++++++----------------- ecrire/install/etape_.php | 4 +-- ecrire/install/etape_1.php | 4 +-- ecrire/install/etape_2.php | 4 +-- ecrire/install/etape_3.php | 4 +-- ecrire/install/etape_4.php | 4 +-- ecrire/install/etape_5.php | 4 +-- ecrire/install/etape_6.php | 4 +-- ecrire/install/etape_ldap1.php | 4 +-- ecrire/install/etape_ldap2.php | 4 +-- ecrire/install/etape_ldap3.php | 4 +-- ecrire/install/etape_ldap4.php | 4 +-- ecrire/install/etape_ldap5.php | 4 ++- 17 files changed, 66 insertions(+), 64 deletions(-) diff --git a/ecrire/action/pass.php b/ecrire/action/pass.php index 590400063f..722df39703 100644 --- a/ecrire/action/pass.php +++ b/ecrire/action/pass.php @@ -105,8 +105,8 @@ $message = ''; // http://doc.spip.org/@action_pass_dist function action_pass_dist() { - install_debut_html( _T('pass_mot_oublie')); + echo install_debut_html( _T('pass_mot_oublie')); inclure_balise_dynamique(formulaire_oubli_dyn(_request('p'), _request('oubli'))); - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/exec/convert_utf8.php b/ecrire/exec/convert_utf8.php index 5da7edf553..20c4c6b593 100644 --- a/ecrire/exec/convert_utf8.php +++ b/ecrire/exec/convert_utf8.php @@ -120,7 +120,7 @@ function exec_convert_utf8_dist() { // commencer (ou continuer apres un timeout et reload) - install_debut_html($action); + echo install_debut_html($action); echo "<p>" . _T('utf8_convert_timeout') . "<hr />\n"; @@ -208,7 +208,7 @@ function exec_convert_utf8_dist() { echo "<p align='right'> <a href='" . generer_url_ecrire("config_lang") . "'> >> "._T('icone_retour')."</a>"; - install_fin_html(); + echo install_fin_html(); } diff --git a/ecrire/exec/export_all.php b/ecrire/exec/export_all.php index e509e9c247..70e0b77366 100644 --- a/ecrire/exec/export_all.php +++ b/ecrire/exec/export_all.php @@ -93,7 +93,7 @@ function exec_export_all_dist() $start = ($status_dump[2]==0)&&($status_dump[3]==0); } - install_debut_html(_T('info_sauvegarde')); + echo install_debut_html(_T('info_sauvegarde')); $file = $dir . $archive; $partfile = $file . ".part"; @@ -252,7 +252,7 @@ function exec_export_all_dist() echo ("<script language=\"JavaScript\" type=\"text/javascript\">window.setTimeout('location.href=\"".str_replace("&","&",generer_url_ecrire("export_all","archive=$archive&gz=$gz"))."\";',0);</script>\n"); } - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/exec/upgrade.php b/ecrire/exec/upgrade.php index a47e055b7c..86208185c0 100644 --- a/ecrire/exec/upgrade.php +++ b/ecrire/exec/upgrade.php @@ -28,7 +28,7 @@ function exec_upgrade_dist() { @copy(_FILE_CONNECT, _FILE_CONNECT_INS); - install_debut_html(_T('titre_page_upgrade')); + echo install_debut_html(_T('titre_page_upgrade')); echo "<p><b>",_T('texte_nouvelle_version_spip_1'),"</b><p> ", _T('texte_nouvelle_version_spip_2', array('connect' => '<tt>' . _FILE_CONNECT . '</tt>')), @@ -39,7 +39,7 @@ function exec_upgrade_dist() { "\" class='fondl'>", "</form>\n"; - install_fin_html(); + echo install_fin_html(); exit; } diff --git a/ecrire/inc/minipres.php b/ecrire/inc/minipres.php index e9c9e466e8..0c5e15c629 100644 --- a/ecrire/inc/minipres.php +++ b/ecrire/inc/minipres.php @@ -36,33 +36,33 @@ function install_debut_html($titre = 'AUTO', $onLoad = '') { if (!headers_sent()) header('Content-Type: text/html; charset=utf-8'); - echo _DOCTYPE_ECRIRE , - html_lang_attributes(), - "<head>\n", - "<title>", - textebrut($titre), + return _DOCTYPE_ECRIRE. + html_lang_attributes(). + "<head>\n". + "<title>". + textebrut($titre). "</title> - <style type='text/css'><!--\n/*<![CDATA[*/\n\n\n", - "body { background: #FFF; color: #000; }\n", - "h1 { color: #970038; margin-top: 50px; font-family: Verdana; font-weigth: bold; font-size: 18px }\n", - "h2 { font-family: Verdana,Arial,Sans,sans-serif; font-weigth: normal; font-size: 100%; }\n", - "a { color: #E86519; text-decoration: none; }\n", - "a:visited { color: #6E003A; }\n", - "a:active { color: #FF9900; }\n", - "img { border: 0; }\n", - "p { text-align: justify; }\n", - "ul { text-align: justify; list-style-type: none; }\n", - "fieldset, .fieldset { font-weigth: bold; text-align: justify; border: 1px solid #444; paddind: 10px; margin-top: 1em; }\n", - "legend { font-weight: bold; }\n", - "label {}\n", - "#minipres { width: 30em; text-align: center; margin-left: auto; margin-right: auto; }\n", - ".petit-centre { font-family: Verdana,Arial,Sans,sans-serif; font-size: 10px; }\n", - ".petit-centre p { text-align: center; }\n", - ".suivant { text-align: $spip_lang_right; display: block; margin-top: 1em; }\n", + <style type='text/css'><!--\n/*<![CDATA[*/\n\n\n". + "body { background: #FFF; color: #000; }\n". + "h1 { color: #970038; margin-top: 50px; font-family: Verdana; font-weigth: bold; font-size: 18px }\n". + "h2 { font-family: Verdana,Arial,Sans,sans-serif; font-weigth: normal; font-size: 100%; }\n". + "a { color: #E86519; text-decoration: none; }\n". + "a:visited { color: #6E003A; }\n". + "a:active { color: #FF9900; }\n". + "img { border: 0; }\n". + "p { text-align: justify; }\n". + "ul { text-align: justify; list-style-type: none; }\n". + "fieldset, .fieldset { font-weigth: bold; text-align: justify; border: 1px solid #444; paddind: 10px; margin-top: 1em; }\n". + "legend { font-weight: bold; }\n". + "label {}\n". + "#minipres { width: 30em; text-align: center; margin-left: auto; margin-right: auto; }\n". + ".petit-centre { font-family: Verdana,Arial,Sans,sans-serif; font-size: 10px; }\n". + ".petit-centre p { text-align: center; }\n". + ".suivant { text-align: $spip_lang_right; display: block; margin-top: 1em; }\n". ".fondl { padding: 3px; background-color: #eee; border: 1px solid #333; background-position: center bottom; font-size: 0.8em; - font-family: Verdana,Arial,Sans,sans-serif; }\n", + font-family: Verdana,Arial,Sans,sans-serif; }\n". ".formo { width: 100%; display: block; padding: 3px; margin-top: 1em; background-color: #FFF; @@ -70,22 +70,22 @@ function install_debut_html($titre = 'AUTO', $onLoad = '') { background-position: center bottom; behavior: url(../dist/win_width.htc); font-size: 0.8em; - font-family: Verdana,Arial,Sans,sans-serif; }\n", + font-family: Verdana,Arial,Sans,sans-serif; }\n". "\n\n]]>\n--></style>\n\n <script type='text/javascript' src='" . _DIR_JAVASCRIPT . "spip_barre.js'></script> </head> <body".$onLoad."> <div id='minipres'> - <h1>", - $titre , + <h1>". + $titre . "</h1> <div>\n"; } // http://doc.spip.org/@install_fin_html function install_fin_html() { - echo "\n\t</div>\n\t</div>\n</body>\n</html>"; + return "\n\t</div>\n\t</div>\n</body>\n</html>"; } // http://doc.spip.org/@info_etape @@ -129,14 +129,14 @@ function bouton_suivant($code = 'suivant') { function minipres($titre, $corps="", $onload='') { if (!$titre) - echo _DOCTYPE_ECRIRE , - html_lang_attributes(), - "<body$onload>", - $corps, + return _DOCTYPE_ECRIRE. + html_lang_attributes(). + "<body$onload>". + $corps. '</body></html>'; else { - install_debut_html($titre, $onload); - echo $corps; + return install_debut_html($titre, $onload). + $corps. install_fin_html(); } exit; diff --git a/ecrire/install/etape_.php b/ecrire/install/etape_.php index cc36d92253..2ccf435b38 100644 --- a/ecrire/install/etape_.php +++ b/ecrire/install/etape_.php @@ -22,7 +22,7 @@ function install_etape__dist() include_spip('inc/headers'); redirige_par_entete(generer_url_action('test_dirs')); } else { - install_debut_html(); + echo install_debut_html(); echo "<div><img alt='SPIP' src='" . _DIR_IMG_PACK . "logo-spip.gif' /></div>\n", "<div class='petit-centre'><p>",info_copyright(),"</p></div>\n", "<p>",_T('install_select_langue'),"</p>", @@ -31,7 +31,7 @@ function install_etape__dist() '<input type="hidden" name="action" value="test_dirs" />', bouton_suivant(), "</form>"; - install_fin_html(); + echo install_fin_html(); } } diff --git a/ecrire/install/etape_1.php b/ecrire/install/etape_1.php index 46d0aaff05..58bb6a3e62 100644 --- a/ecrire/install/etape_1.php +++ b/ecrire/install/etape_1.php @@ -15,7 +15,7 @@ function install_etape_1_dist() { global $spip_lang_right; - install_debut_html(); + echo install_debut_html(); // stopper en cas de grosse incompatibilite de l'hebergement tester_compatibilite_hebergement(); @@ -78,7 +78,7 @@ function install_etape_1_dist() echo bouton_suivant(); echo "</form>"; - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_2.php b/ecrire/install/etape_2.php index 6f7ff959b0..5ff11cf79c 100644 --- a/ecrire/install/etape_2.php +++ b/ecrire/install/etape_2.php @@ -15,7 +15,7 @@ function install_etape_2_dist() { global $adresse_db, $login_db, $pass_db, $spip_lang_right,$chmod; - install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); + echo install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); echo info_etape(_T('info_connexion_base')); @@ -43,7 +43,7 @@ function install_etape_2_dist() echo "<p style='font-size: small;'>"._T('avis_connexion_echec_3')."</p>"; } - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_3.php b/ecrire/install/etape_3.php index 2ccff63376..2cb1972f17 100644 --- a/ecrire/install/etape_3.php +++ b/ecrire/install/etape_3.php @@ -15,7 +15,7 @@ function install_etape_3_dist() { global $adresse_db, $login_db, $pass_db, $spip_lang_right, $chmod; - install_debut_html(); + echo install_debut_html(); echo info_etape(_T('info_choix_base')." "._T('menu_aide_installation_choix_base').aide ("install2")); @@ -84,7 +84,7 @@ function install_etape_3_dist() echo bouton_suivant(); echo "</form>"; - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_4.php b/ecrire/install/etape_4.php index 645bb23ca5..a705fec0ed 100644 --- a/ecrire/install/etape_4.php +++ b/ecrire/install/etape_4.php @@ -19,7 +19,7 @@ function install_etape_4_dist() { global $adresse_db, $choix_db, $login_db, $pass_db, $spip_lang_right, $spip_version, $table_new, $chmod; - install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); + echo install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); echo info_etape(_T('info_creation_tables')); @@ -113,7 +113,7 @@ function install_etape_4_dist() echo "<B>"._T('avis_operation_echec')."</B> "._T('texte_operation_echec'); } - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_5.php b/ecrire/install/etape_5.php index 719a281335..cf32f16605 100644 --- a/ecrire/install/etape_5.php +++ b/ecrire/install/etape_5.php @@ -19,7 +19,7 @@ function install_etape_5_dist() { global $email, $ldap_present, $login, $nom, $pass, $spip_lang_right; - install_debut_html(); + echo install_debut_html(); if (@file_exists(_FILE_CONNECT_INS . _FILE_TMP . '.php')) include(_FILE_CONNECT_INS . _FILE_TMP . '.php'); @@ -86,7 +86,7 @@ function install_etape_5_dist() echo "</form>\n"; } - install_fin_html(); + echo install_fin_html(); } ?> \ No newline at end of file diff --git a/ecrire/install/etape_6.php b/ecrire/install/etape_6.php index f31458edd3..cf3266a0da 100644 --- a/ecrire/install/etape_6.php +++ b/ecrire/install/etape_6.php @@ -19,7 +19,7 @@ function install_etape_6_dist() { global $email,$login,$nom,$pass,$spip_lang_right; - install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); + echo install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); echo info_etape(_T('info_derniere_etape'), "<b>"._T('info_code_acces')."</b></p><p>" . @@ -99,7 +99,7 @@ function install_etape_6_dist() ecrire_metas(); - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_ldap1.php b/ecrire/install/etape_ldap1.php index a1d4a32f9b..04d05275e2 100644 --- a/ecrire/install/etape_ldap1.php +++ b/ecrire/install/etape_ldap1.php @@ -27,7 +27,7 @@ function install_etape_ldap1_dist() $port_ldap = $regs[2]; } } - install_debut_html(); + echo install_debut_html(); echo info_etape(_T('titre_connexion_ldap'), _T('entree_informations_connexion_ldap')); @@ -80,7 +80,7 @@ function install_etape_ldap1_dist() echo bouton_suivant(); echo "</form>"; - install_fin_html(); + echo install_fin_html(); } ?> \ No newline at end of file diff --git a/ecrire/install/etape_ldap2.php b/ecrire/install/etape_ldap2.php index 7ecac7fb2a..ac615198ce 100644 --- a/ecrire/install/etape_ldap2.php +++ b/ecrire/install/etape_ldap2.php @@ -16,7 +16,7 @@ function install_etape_ldap2_dist() { global $adresse_ldap, $login_ldap, $pass_ldap, $port_ldap, $tls_ldap, $protocole_ldap, $spip_lang_right; - install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); + echo install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); $port_ldap = intval($port_ldap); $ldap_link = @ldap_connect($adresse_ldap, $port_ldap); @@ -63,7 +63,7 @@ function install_etape_ldap2_dist() ); } - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_ldap3.php b/ecrire/install/etape_ldap3.php index e880642325..117622649e 100644 --- a/ecrire/install/etape_ldap3.php +++ b/ecrire/install/etape_ldap3.php @@ -16,7 +16,7 @@ function install_etape_ldap3_dist() { global $adresse_ldap, $login_ldap, $pass_ldap, $port_ldap, $tls_ldap, $protocole_ldap, $spip_lang_right; - install_debut_html(); + echo install_debut_html(); echo info_etape(_T('info_chemin_acces_1'),_T('info_chemin_acces_2')); @@ -74,7 +74,7 @@ function install_etape_ldap3_dist() echo bouton_suivant(); echo "</form>"; - install_fin_html(); + echo install_fin_html(); } diff --git a/ecrire/install/etape_ldap4.php b/ecrire/install/etape_ldap4.php index 4a848851d5..75f3ead501 100644 --- a/ecrire/install/etape_ldap4.php +++ b/ecrire/install/etape_ldap4.php @@ -15,7 +15,7 @@ function install_etape_ldap4_dist() { global $adresse_ldap, $login_ldap, $pass_ldap, $port_ldap, $tls_ldap, $protocole_ldap, $base_ldap, $base_ldap_text, $spip_lang_right; - install_debut_html(); + echo install_debut_html(); if (!$base_ldap) $base_ldap = $base_ldap_text; @@ -75,6 +75,6 @@ function install_etape_ldap4_dist() echo "</form>"; } - install_fin_html(); + echo install_fin_html(); } ?> diff --git a/ecrire/install/etape_ldap5.php b/ecrire/install/etape_ldap5.php index 9b1a6350e1..0d171f60a8 100644 --- a/ecrire/install/etape_ldap5.php +++ b/ecrire/install/etape_ldap5.php @@ -18,7 +18,7 @@ function install_etape_ldap5_dist() { global $spip_lang_right, $statut_ldap; - install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); + echo install_debut_html('AUTO', ' onLoad="document.getElementById(\'suivant\').focus();return false;"'); // simuler ecrire_meta/s pour pouvoir sauver le statut // car _FILE_CONNECT est defa a False a ce moment. @@ -38,6 +38,8 @@ function install_etape_ldap5_dist() echo bouton_suivant(); echo "</form>"; + + echo install_fin_html(); } ?> \ No newline at end of file -- GitLab