@@ -21,7 +21,7 @@ discard block |
||
| 21 | 21 | |
| 22 | 22 | // creer le repertoire cache, qui sert partout ! |
| 23 | 23 | if (!@file_exists(_DIR_CACHE)) { |
| 24 | - $rep = preg_replace(',' . _DIR_TMP . ',', '', _DIR_CACHE); |
|
| 24 | + $rep = preg_replace(','._DIR_TMP.',', '', _DIR_CACHE); |
|
| 25 | 25 | $rep = sous_repertoire(_DIR_TMP, $rep, true, true); |
| 26 | 26 | } |
| 27 | 27 | |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | echo '<p>' |
| 40 | 40 | . _T( |
| 41 | 41 | 'plugin_info_plugins_dist_1', |
| 42 | - array('plugins_dist' => '<tt>' . joli_repertoire(_DIR_PLUGINS_DIST) . '</tt>') |
|
| 42 | + array('plugins_dist' => '<tt>'.joli_repertoire(_DIR_PLUGINS_DIST).'</tt>') |
|
| 43 | 43 | ) |
| 44 | 44 | . '</p>'; |
| 45 | 45 | |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | echo info_etape( |
| 67 | 67 | _T('titre_connexion_ldap'), |
| 68 | 68 | info_progression_etape(2, 'etape_ldap', 'install/') |
| 69 | - ), _T('info_connexion_ldap_ok'); |
|
| 69 | + ), _T('info_connexion_ldap_ok'); |
|
| 70 | 70 | echo generer_form_ecrire('install', ( |
| 71 | 71 | "\n<input type='hidden' name='etape' value='ldap3' />" |
| 72 | 72 | . "\n<input type='hidden' name='adresse_ldap' value=\"$adresse_ldap\" />" |
@@ -78,10 +78,10 @@ discard block |
||
| 78 | 78 | . bouton_suivant())); |
| 79 | 79 | } else { |
| 80 | 80 | echo info_etape(_T('titre_connexion_ldap')), info_progression_etape(1, 'etape_ldap', 'install/', true), |
| 81 | - "<div class='error'><p>" . _T('avis_connexion_ldap_echec_1') . '</p>', |
|
| 82 | - '<p>' . _T('avis_connexion_ldap_echec_2') . |
|
| 83 | - "<br />\n" . _T('avis_connexion_ldap_echec_3') . |
|
| 84 | - '<br /><br />' . $erreur . '<b> ?</b></p></div>'; |
|
| 81 | + "<div class='error'><p>"._T('avis_connexion_ldap_echec_1').'</p>', |
|
| 82 | + '<p>'._T('avis_connexion_ldap_echec_2'). |
|
| 83 | + "<br />\n"._T('avis_connexion_ldap_echec_3'). |
|
| 84 | + '<br /><br />'.$erreur.'<b> ?</b></p></div>'; |
|
| 85 | 85 | } |
| 86 | 86 | |
| 87 | 87 | echo install_fin_html(); |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | $checked = false; |
| 46 | 46 | $res = ''; |
| 47 | 47 | if (is_array($info) and $info['count'] > 0) { |
| 48 | - $res .= '<p>' . _T('info_selection_chemin_acces') . '</p>'; |
|
| 48 | + $res .= '<p>'._T('info_selection_chemin_acces').'</p>'; |
|
| 49 | 49 | $res .= '<ul>'; |
| 50 | 50 | $n = 0; |
| 51 | 51 | for ($i = 0; $i < $info['count']; $i++) { |
@@ -53,18 +53,18 @@ discard block |
||
| 53 | 53 | if (is_array($names)) { |
| 54 | 54 | for ($j = 0; $j < $names['count']; $j++) { |
| 55 | 55 | $n++; |
| 56 | - $res .= '<li><input name="base_ldap" value="' . spip_htmlspecialchars($names[$j]) . "\" type='radio' id='tab$n'"; |
|
| 56 | + $res .= '<li><input name="base_ldap" value="'.spip_htmlspecialchars($names[$j])."\" type='radio' id='tab$n'"; |
|
| 57 | 57 | if (!$checked) { |
| 58 | 58 | $res .= ' checked="checked"'; |
| 59 | 59 | $checked = true; |
| 60 | 60 | } |
| 61 | 61 | $res .= ' />'; |
| 62 | - $res .= "<label for='tab$n'>" . spip_htmlspecialchars($names[$j]) . "</label></li>\n"; |
|
| 62 | + $res .= "<label for='tab$n'>".spip_htmlspecialchars($names[$j])."</label></li>\n"; |
|
| 63 | 63 | } |
| 64 | 64 | } |
| 65 | 65 | } |
| 66 | 66 | $res .= '</ul>'; |
| 67 | - $res .= _T('info_ou') . ' '; |
|
| 67 | + $res .= _T('info_ou').' '; |
|
| 68 | 68 | } |
| 69 | 69 | $res .= "<br />\n<input name=\"base_ldap\" value=\"\" type='radio' id='manuel'"; |
| 70 | 70 | if (!$checked) { |
@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | } |
| 74 | 74 | |
| 75 | 75 | $res .= ' />' |
| 76 | - . "\n<label for='manuel'>" . _T('entree_chemin_acces') . '</label> ' |
|
| 76 | + . "\n<label for='manuel'>"._T('entree_chemin_acces').'</label> ' |
|
| 77 | 77 | . "\n<fieldset>" |
| 78 | 78 | . "<input type='text' name='base_ldap_text' class='text' value=\"$base_ldap_text\" size='40' />" |
| 79 | 79 | . "\n</fieldset>" |
@@ -52,29 +52,28 @@ discard block |
||
| 52 | 52 | $conn = "\$GLOBALS['ldap_base'] = '$base_ldap';\n" |
| 53 | 53 | . "\$GLOBALS['ldap_link'] = @ldap_connect('$adresse_ldap','$port_ldap');\n" |
| 54 | 54 | . "@ldap_set_option(\$GLOBALS['ldap_link'],LDAP_OPT_PROTOCOL_VERSION,'$protocole_ldap');\n" |
| 55 | - . (($tls_ldap != 'oui') ? '' : |
|
| 56 | - "@ldap_start_tls(\$GLOBALS['ldap_link']);\n") |
|
| 55 | + . (($tls_ldap != 'oui') ? '' : "@ldap_start_tls(\$GLOBALS['ldap_link']);\n") |
|
| 57 | 56 | . "@ldap_bind(\$GLOBALS['ldap_link'],'$login_ldap','$pass_ldap');\n"; |
| 58 | 57 | |
| 59 | 58 | $champs = is_array($GLOBALS['ldap_attributes']) ? $GLOBALS['ldap_attributes'] : array(); |
| 60 | 59 | $res = ''; |
| 61 | 60 | foreach ($champs as $champ => $v) { |
| 62 | - $nom = 'ldap_' . $champ; |
|
| 61 | + $nom = 'ldap_'.$champ; |
|
| 63 | 62 | $val = trim(_request($nom)); |
| 64 | 63 | if (preg_match('/^\w*$/', $val)) { |
| 65 | 64 | if ($val) { |
| 66 | 65 | $val = _q($val); |
| 67 | 66 | } |
| 68 | 67 | } else { |
| 69 | - $val = 'array(' . _q(preg_split('/\W+/', $val)) . ')'; |
|
| 68 | + $val = 'array('._q(preg_split('/\W+/', $val)).')'; |
|
| 70 | 69 | }; |
| 71 | 70 | if ($val) { |
| 72 | - $res .= "'$champ' => " . $val . ','; |
|
| 71 | + $res .= "'$champ' => ".$val.','; |
|
| 73 | 72 | } |
| 74 | 73 | } |
| 75 | 74 | $conn .= "\$GLOBALS['ldap_champs'] = array($res);\n"; |
| 76 | 75 | |
| 77 | - install_fichier_connexion(_DIR_CONNECT . _FILE_LDAP, $conn); |
|
| 76 | + install_fichier_connexion(_DIR_CONNECT._FILE_LDAP, $conn); |
|
| 78 | 77 | } |
| 79 | 78 | |
| 80 | 79 | function etape_ldap5_suite() { |
@@ -87,7 +86,7 @@ discard block |
||
| 87 | 86 | ); |
| 88 | 87 | |
| 89 | 88 | echo generer_form_ecrire('install', ( |
| 90 | - "<input type='hidden' name='etape' value='3' />" . |
|
| 89 | + "<input type='hidden' name='etape' value='3' />". |
|
| 91 | 90 | "<input type='hidden' name='ldap_present' value='true' />" |
| 92 | 91 | . bouton_suivant())); |
| 93 | 92 | |
@@ -34,11 +34,11 @@ |
||
| 34 | 34 | } else { |
| 35 | 35 | include_spip('inc/presentation'); // pour info_copyright |
| 36 | 36 | |
| 37 | - $res = "<div class='petit-centre'><img alt='SPIP' class='logo' src='" . chemin_image('logo-spip.png') . "' />\n" . |
|
| 38 | - "<p class='small'>" . info_copyright() . "</p></div>\n" . |
|
| 39 | - '<p>' . _T('install_select_langue') . '</p>' . |
|
| 40 | - '<div>' . $menu_langues . "</div>\n" . |
|
| 41 | - generer_form_ecrire('install', "<input type='hidden' name='etape' value='chmod' />" . bouton_suivant()); |
|
| 37 | + $res = "<div class='petit-centre'><img alt='SPIP' class='logo' src='".chemin_image('logo-spip.png')."' />\n". |
|
| 38 | + "<p class='small'>".info_copyright()."</p></div>\n". |
|
| 39 | + '<p>'._T('install_select_langue').'</p>'. |
|
| 40 | + '<div>'.$menu_langues."</div>\n". |
|
| 41 | + generer_form_ecrire('install', "<input type='hidden' name='etape' value='chmod' />".bouton_suivant()); |
|
| 42 | 42 | echo minipres('AUTO', $res); |
| 43 | 43 | } |
| 44 | 44 | } |
@@ -40,8 +40,8 @@ discard block |
||
| 40 | 40 | if ($fail) { |
| 41 | 41 | echo info_etape(_T('info_chemin_acces_annuaire')), |
| 42 | 42 | info_progression_etape(3, 'etape_ldap', 'install/', true), |
| 43 | - "<div class='error'><p><b>" . _T('avis_operation_echec') . '</b></p><p>' . _T('avis_chemin_invalide_1'), |
|
| 44 | - ' (<tt>' . spip_htmlspecialchars($base_ldap) . '</tt>) ' . _T('avis_chemin_invalide_2') . '</p></div>'; |
|
| 43 | + "<div class='error'><p><b>"._T('avis_operation_echec').'</b></p><p>'._T('avis_chemin_invalide_1'), |
|
| 44 | + ' (<tt>'.spip_htmlspecialchars($base_ldap).'</tt>) '._T('avis_chemin_invalide_2').'</p></div>'; |
|
| 45 | 45 | } else { |
| 46 | 46 | info_etape(_T('info_reglage_ldap')); |
| 47 | 47 | echo info_progression_etape(4, 'etape_ldap', 'install/'); |
@@ -54,12 +54,12 @@ discard block |
||
| 54 | 54 | |
| 55 | 55 | $res = install_propager(array('adresse_ldap', 'port_ldap', 'login_ldap', 'pass_ldap', 'protocole_ldap', 'tls_ldap')) |
| 56 | 56 | . "<input type='hidden' name='etape' value='ldap5' />" |
| 57 | - . "<input type='hidden' name='base_ldap' value='" . spip_htmlentities($base_ldap) . "' />" |
|
| 57 | + . "<input type='hidden' name='base_ldap' value='".spip_htmlentities($base_ldap)."' />" |
|
| 58 | 58 | . fieldset( |
| 59 | 59 | _T('info_statut_utilisateurs_1'), |
| 60 | 60 | array( |
| 61 | 61 | 'statut_ldap' => array( |
| 62 | - 'label' => _T('info_statut_utilisateurs_2') . '<br />', |
|
| 62 | + 'label' => _T('info_statut_utilisateurs_2').'<br />', |
|
| 63 | 63 | 'valeur' => $statut_ldap, |
| 64 | 64 | 'alternatives' => $statuts |
| 65 | 65 | ) |
@@ -77,9 +77,9 @@ discard block |
||
| 77 | 77 | // http://code.spip.net/@liste_statuts_ldap |
| 78 | 78 | function liste_statuts_ldap() { |
| 79 | 79 | $recom = array( |
| 80 | - 'info_administrateurs' => ('<b>' . _T('info_administrateur_1') . '</b> ' . _T('info_administrateur_2') . '<br />'), |
|
| 81 | - 'info_redacteurs' => ('<b>' . _T('info_redacteur_1') . '</b> ' . _T('info_redacteur_2') . '<br />'), |
|
| 82 | - 'info_visiteurs' => ('<b>' . _T('info_visiteur_1') . '</b> ' . _T('info_visiteur_2') . '<br />') |
|
| 80 | + 'info_administrateurs' => ('<b>'._T('info_administrateur_1').'</b> '._T('info_administrateur_2').'<br />'), |
|
| 81 | + 'info_redacteurs' => ('<b>'._T('info_redacteur_1').'</b> '._T('info_redacteur_2').'<br />'), |
|
| 82 | + 'info_visiteurs' => ('<b>'._T('info_visiteur_1').'</b> '._T('info_visiteur_2').'<br />') |
|
| 83 | 83 | ); |
| 84 | 84 | |
| 85 | 85 | $res = array(); |
@@ -95,14 +95,14 @@ discard block |
||
| 95 | 95 | function install_ldap_correspondances() { |
| 96 | 96 | $champs = array(); |
| 97 | 97 | foreach (is_array($GLOBALS['ldap_attributes']) ? $GLOBALS['ldap_attributes'] : array() as $champ => $v) { |
| 98 | - $nom = 'ldap_' . $champ; |
|
| 98 | + $nom = 'ldap_'.$champ; |
|
| 99 | 99 | $val = is_array($v) ? join(',', $v) : strval($v); |
| 100 | 100 | $champs[$nom] = array( |
| 101 | - 'label' => _T('ldap_correspondance', array('champ' => "<tt>$champ</tt>")) . '<br />', |
|
| 101 | + 'label' => _T('ldap_correspondance', array('champ' => "<tt>$champ</tt>")).'<br />', |
|
| 102 | 102 | 'valeur' => $val |
| 103 | 103 | ); |
| 104 | 104 | } |
| 105 | 105 | |
| 106 | 106 | return !$champs ? |
| 107 | - '' : fieldset(_T('ldap_correspondance_1'), $champs, '', _T('ldap_correspondance_2') . '<br /><br />'); |
|
| 107 | + '' : fieldset(_T('ldap_correspondance_1'), $champs, '', _T('ldap_correspondance_2').'<br /><br />'); |
|
| 108 | 108 | } |
@@ -32,9 +32,9 @@ discard block |
||
| 32 | 32 | // Faut-il initialiser SPIP ? (oui dans le cas general) |
| 33 | 33 | if (!defined('_DIR_RESTREINT_ABS')) { |
| 34 | 34 | if (defined('_DIR_RESTREINT') |
| 35 | - and @file_exists(_ROOT_RESTREINT . 'inc_version.php') |
|
| 35 | + and @file_exists(_ROOT_RESTREINT.'inc_version.php') |
|
| 36 | 36 | ) { |
| 37 | - include_once _ROOT_RESTREINT . 'inc_version.php'; |
|
| 37 | + include_once _ROOT_RESTREINT.'inc_version.php'; |
|
| 38 | 38 | } else { |
| 39 | 39 | die('inc_version absent ?'); |
| 40 | 40 | } |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | } // fond demande dans l'url par page=xxxx ? |
| 46 | 46 | else { |
| 47 | 47 | if (isset($_GET[_SPIP_PAGE])) { |
| 48 | - $fond = (string)$_GET[_SPIP_PAGE]; |
|
| 48 | + $fond = (string) $_GET[_SPIP_PAGE]; |
|
| 49 | 49 | |
| 50 | 50 | // Securite |
| 51 | 51 | if (strstr($fond, '/') |
@@ -107,7 +107,7 @@ discard block |
||
| 107 | 107 | // lancer les taches sur affichage final, comme le cron |
| 108 | 108 | // mais sans rien afficher |
| 109 | 109 | $GLOBALS['html'] = false; // ne rien afficher |
| 110 | - pipeline('affichage_final' . _PIPELINE_SUFFIX, ''); |
|
| 110 | + pipeline('affichage_final'._PIPELINE_SUFFIX, ''); |
|
| 111 | 111 | exit; // le hit est fini ! |
| 112 | 112 | } |
| 113 | 113 | } |
@@ -124,7 +124,7 @@ discard block |
||
| 124 | 124 | // Content-Type ? |
| 125 | 125 | if (!isset($page['entetes']['Content-Type'])) { |
| 126 | 126 | $charset = isset($GLOBALS['meta']['charset']) ? $GLOBALS['meta']['charset'] : "utf-8"; |
| 127 | - $page['entetes']['Content-Type'] = 'text/html; charset=' . $charset; |
|
| 127 | + $page['entetes']['Content-Type'] = 'text/html; charset='.$charset; |
|
| 128 | 128 | $html = true; |
| 129 | 129 | } else { |
| 130 | 130 | $html = preg_match(',^\s*text/html,', $page['entetes']['Content-Type']); |
@@ -150,11 +150,11 @@ discard block |
||
| 150 | 150 | |
| 151 | 151 | // traitements sur les entetes avant envoi |
| 152 | 152 | // peut servir pour le plugin de stats |
| 153 | - $page['entetes'] = pipeline('affichage_entetes_final' . _PIPELINE_SUFFIX, $page['entetes']); |
|
| 153 | + $page['entetes'] = pipeline('affichage_entetes_final'._PIPELINE_SUFFIX, $page['entetes']); |
|
| 154 | 154 | |
| 155 | 155 | |
| 156 | 156 | // eval $page et affecte $res |
| 157 | - include _ROOT_RESTREINT . "public/evaluer_page.php"; |
|
| 157 | + include _ROOT_RESTREINT."public/evaluer_page.php"; |
|
| 158 | 158 | envoyer_entetes($page['entetes']); |
| 159 | 159 | if ($res === false) { |
| 160 | 160 | include_spip('inc/autoriser'); |
@@ -173,7 +173,7 @@ discard block |
||
| 173 | 173 | // |
| 174 | 174 | // (c'est ici qu'on fait var_recherche, validation, boutons d'admin, |
| 175 | 175 | // cf. public/assembler.php) |
| 176 | - echo pipeline('affichage_final' . _PIPELINE_SUFFIX, $page['texte']); |
|
| 176 | + echo pipeline('affichage_final'._PIPELINE_SUFFIX, $page['texte']); |
|
| 177 | 177 | |
| 178 | 178 | if ($lang) { |
| 179 | 179 | lang_select(); |
@@ -189,7 +189,7 @@ discard block |
||
| 189 | 189 | if ($html and ($affiche_boutons_admin or $debug)) { |
| 190 | 190 | $var_mode_affiche = _request('var_mode_affiche'); |
| 191 | 191 | $var_mode_objet = _request('var_mode_objet'); |
| 192 | - $GLOBALS['debug_objets'][$var_mode_affiche][$var_mode_objet . 'tout'] = ($var_mode_affiche == 'validation' ? $page['texte'] : ""); |
|
| 192 | + $GLOBALS['debug_objets'][$var_mode_affiche][$var_mode_objet.'tout'] = ($var_mode_affiche == 'validation' ? $page['texte'] : ""); |
|
| 193 | 193 | echo erreur_squelette(false); |
| 194 | 194 | } |
| 195 | 195 | } else { |
@@ -107,8 +107,8 @@ |
||
| 107 | 107 | function message_crash_tables() { |
| 108 | 108 | if ($crash = verifier_crash_tables()) { |
| 109 | 109 | return |
| 110 | - '<strong>' . _T('texte_recuperer_base') . '</strong><br />' |
|
| 111 | - . ' <tt>' . join(', ', $crash) . '</tt><br />' |
|
| 110 | + '<strong>'._T('texte_recuperer_base').'</strong><br />' |
|
| 111 | + . ' <tt>'.join(', ', $crash).'</tt><br />' |
|
| 112 | 112 | . generer_form_ecrire('base_repair', |
| 113 | 113 | _T('texte_crash_base'), '', |
| 114 | 114 | _T('bouton_tenter_recuperation')); |
@@ -29,11 +29,11 @@ discard block |
||
| 29 | 29 | function genie_mise_a_jour_dist($t) { |
| 30 | 30 | include_spip('inc/meta'); |
| 31 | 31 | $maj = info_maj('spip', 'SPIP', $GLOBALS['spip_version_branche']); |
| 32 | - ecrire_meta('info_maj_spip', $maj ? ($GLOBALS['spip_version_branche'] . "|$maj") : "", 'non'); |
|
| 32 | + ecrire_meta('info_maj_spip', $maj ? ($GLOBALS['spip_version_branche']."|$maj") : "", 'non'); |
|
| 33 | 33 | |
| 34 | 34 | mise_a_jour_ecran_securite(); |
| 35 | 35 | |
| 36 | - spip_log("Verification version SPIP : " . ($maj ? $maj : "version a jour"), "verifie_maj"); |
|
| 36 | + spip_log("Verification version SPIP : ".($maj ? $maj : "version a jour"), "verifie_maj"); |
|
| 37 | 37 | |
| 38 | 38 | return 1; |
| 39 | 39 | } |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | |
| 58 | 58 | // si l'ecran n'est pas deja present ou pas updatable, sortir |
| 59 | 59 | if (!_URL_ECRAN_SECURITE |
| 60 | - or !file_exists($filename = _DIR_ETC . "ecran_securite.php") |
|
| 60 | + or !file_exists($filename = _DIR_ETC."ecran_securite.php") |
|
| 61 | 61 | or !is_writable($filename) |
| 62 | 62 | or !$last_modified = filemtime($filename) |
| 63 | 63 | or !$md5 = md5_file($filename) |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | } |
| 67 | 67 | |
| 68 | 68 | include_spip('inc/distant'); |
| 69 | - $tmp_file = _DIR_TMP . "ecran_securite.php"; |
|
| 69 | + $tmp_file = _DIR_TMP."ecran_securite.php"; |
|
| 70 | 70 | $url = parametre_url(_URL_ECRAN_SECURITE, "md5", $md5); |
| 71 | 71 | $url = parametre_url($url, "vspip", $GLOBALS['spip_version_branche']); |
| 72 | 72 | $res = recuperer_url($url, array( |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | include_once $tmp_file; |
| 86 | 86 | // ok, on le copie a la place de l'ecran existant |
| 87 | 87 | // en backupant l'ecran avant, au cas ou |
| 88 | - @copy($filename, $filename . "-bck-" . date('Y-m-d-His', $last_modified)); |
|
| 88 | + @copy($filename, $filename."-bck-".date('Y-m-d-His', $last_modified)); |
|
| 89 | 89 | @rename($tmp_file, $filename); |
| 90 | 90 | } else { |
| 91 | 91 | @unlink($tmp_file); |
@@ -112,14 +112,14 @@ discard block |
||
| 112 | 112 | |
| 113 | 113 | list($maj, $min, $rev) = preg_split('/\D+/', $version); |
| 114 | 114 | |
| 115 | - $nom = _DIR_CACHE_XML . _VERSIONS_LISTE; |
|
| 115 | + $nom = _DIR_CACHE_XML._VERSIONS_LISTE; |
|
| 116 | 116 | $page = !file_exists($nom) ? '' : file_get_contents($nom); |
| 117 | 117 | $page = info_maj_cache($nom, $dir, $page); |
| 118 | 118 | |
| 119 | 119 | // reperer toutes les versions de numero majeur superieur ou egal |
| 120 | 120 | // (a revoir quand on arrivera a SPIP V10 ...) |
| 121 | 121 | $p = substr("0123456789", intval($maj)); |
| 122 | - $p = ',/' . $file . '\D+([' . $p . ']+)\D+(\d+)(\D+(\d+))?.*?[.]zip",i'; |
|
| 122 | + $p = ',/'.$file.'\D+(['.$p.']+)\D+(\d+)(\D+(\d+))?.*?[.]zip",i'; |
|
| 123 | 123 | preg_match_all($p, $page, $m, PREG_SET_ORDER); |
| 124 | 124 | $page = $page_majeure = ''; |
| 125 | 125 | |
@@ -128,9 +128,9 @@ discard block |
||
| 128 | 128 | |
| 129 | 129 | foreach ($m as $v) { |
| 130 | 130 | $v = array_pad($v, 5, 0); |
| 131 | - list(, $maj2, $min2, , $rev2) = $v; |
|
| 132 | - $branche_maj = $maj2 . '.' . $min2; |
|
| 133 | - $version_maj = $maj2 . '.' . $min2 . '.' . $rev2; |
|
| 131 | + list(, $maj2, $min2,, $rev2) = $v; |
|
| 132 | + $branche_maj = $maj2.'.'.$min2; |
|
| 133 | + $version_maj = $maj2.'.'.$min2.'.'.$rev2; |
|
| 134 | 134 | // d'abord les mises à jour de la même branche |
| 135 | 135 | if ((spip_version_compare($version, $version_maj, '<')) |
| 136 | 136 | and (spip_version_compare($page, $version_maj, '<')) |
@@ -150,10 +150,10 @@ discard block |
||
| 150 | 150 | return ""; |
| 151 | 151 | } |
| 152 | 152 | |
| 153 | - $message = $page ? _T('nouvelle_version_spip', array('version' => $page)) . ($page_majeure ? ' | ' : '') : ''; |
|
| 153 | + $message = $page ? _T('nouvelle_version_spip', array('version' => $page)).($page_majeure ? ' | ' : '') : ''; |
|
| 154 | 154 | $message .= $page_majeure ? _T('nouvelle_version_spip_majeure', array('version' => $page_majeure)) : ''; |
| 155 | 155 | |
| 156 | - return "<a class='info_maj_spip' href='https://www.spip.net/fr_update' title='$page'>" . $message . '</a>'; |
|
| 156 | + return "<a class='info_maj_spip' href='https://www.spip.net/fr_update' title='$page'>".$message.'</a>'; |
|
| 157 | 157 | } |
| 158 | 158 | |
| 159 | 159 | /** |
@@ -176,12 +176,12 @@ discard block |
||
| 176 | 176 | function info_maj_cache($nom, $dir, $page = '') { |
| 177 | 177 | include_spip('inc/acces'); |
| 178 | 178 | $alea_ephemere = charger_aleas(); |
| 179 | - $re = '<archives id="a' . $alea_ephemere . '">'; |
|
| 179 | + $re = '<archives id="a'.$alea_ephemere.'">'; |
|
| 180 | 180 | if (preg_match("/$re/", $page)) { |
| 181 | 181 | return $page; |
| 182 | 182 | } |
| 183 | 183 | |
| 184 | - $url = _VERSIONS_SERVEUR . $dir . '/' . _VERSIONS_LISTE; |
|
| 184 | + $url = _VERSIONS_SERVEUR.$dir.'/'._VERSIONS_LISTE; |
|
| 185 | 185 | $a = file_exists($nom) ? filemtime($nom) : ''; |
| 186 | 186 | include_spip('inc/distant'); |
| 187 | 187 | $res = recuperer_url_cache($url, array('if_modified_since' => $a)); |