@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | } |
| 92 | 92 | |
| 93 | 93 | |
| 94 | - $row = sql_fetsel($select, $desc['table'], "$_id_objet=" . intval($id_objet)); |
|
| 94 | + $row = sql_fetsel($select, $desc['table'], "$_id_objet=".intval($id_objet)); |
|
| 95 | 95 | $statut = isset($row['statut']) ? $row['statut'] : 'publie'; // pas de statut => publie |
| 96 | 96 | |
| 97 | 97 | $valeurs['editable'] = autoriser('dater', $objet, $id_objet, null, ['statut' => $statut]); |
@@ -248,9 +248,9 @@ discard block |
||
| 248 | 248 | |
| 249 | 249 | if (_request('changer')) { |
| 250 | 250 | foreach (['date', 'date_redac'] as $k) { |
| 251 | - if ($v = _request($k . '_jour') and !dater_recuperer_date_saisie($v, $k)) { |
|
| 251 | + if ($v = _request($k.'_jour') and !dater_recuperer_date_saisie($v, $k)) { |
|
| 252 | 252 | $erreurs[$k] = _T('format_date_incorrecte'); |
| 253 | - } elseif ($v = _request($k . '_heure') and !dater_recuperer_heure_saisie($v)) { |
|
| 253 | + } elseif ($v = _request($k.'_heure') and !dater_recuperer_heure_saisie($v)) { |
|
| 254 | 254 | $erreurs[$k] = _T('format_heure_incorrecte'); |
| 255 | 255 | } |
| 256 | 256 | } |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | function formulaires_configurer_ecran_connexion_data(): array { |
| 4 | 4 | return [ |
| 5 | 5 | 'couleur_defaut' => '#db1762', |
| 6 | - 'img_fond' => _DIR_IMG . 'spip_fond_login.jpg', |
|
| 6 | + 'img_fond' => _DIR_IMG.'spip_fond_login.jpg', |
|
| 7 | 7 | ]; |
| 8 | 8 | } |
| 9 | 9 | |
@@ -77,19 +77,19 @@ discard block |
||
| 77 | 77 | } |
| 78 | 78 | switch ($objet) { |
| 79 | 79 | case 'article': |
| 80 | - $libelle .= ' ' . aider('logoart'); |
|
| 80 | + $libelle .= ' '.aider('logoart'); |
|
| 81 | 81 | break; |
| 82 | 82 | case 'breve': |
| 83 | - $libelle .= ' ' . aider('breveslogo'); |
|
| 83 | + $libelle .= ' '.aider('breveslogo'); |
|
| 84 | 84 | break; |
| 85 | 85 | case 'rubrique': |
| 86 | - $libelle .= ' ' . aider('rublogo'); |
|
| 86 | + $libelle .= ' '.aider('rublogo'); |
|
| 87 | 87 | break; |
| 88 | 88 | default: |
| 89 | 89 | break; |
| 90 | 90 | } |
| 91 | 91 | |
| 92 | - $options['titre'] = $img . $libelle; |
|
| 92 | + $options['titre'] = $img.$libelle; |
|
| 93 | 93 | } |
| 94 | 94 | if (!isset($options['editable'])) { |
| 95 | 95 | include_spip('inc/autoriser'); |
@@ -114,7 +114,7 @@ discard block |
||
| 114 | 114 | foreach ($etats as $etat) { |
| 115 | 115 | $logo = $chercher_logo($id_objet, $_id_objet, $etat); |
| 116 | 116 | if ($logo) { |
| 117 | - $res['logo_' . $etat] = $logo[0]; |
|
| 117 | + $res['logo_'.$etat] = $logo[0]; |
|
| 118 | 118 | } |
| 119 | 119 | } |
| 120 | 120 | // pas de logo_on -> pas de formulaire pour le survol |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | $extensions_possibles |
| 181 | 181 | ) |
| 182 | 182 | ) { |
| 183 | - $erreurs['logo_' . $etat] = _L('Extension non reconnue'); |
|
| 183 | + $erreurs['logo_'.$etat] = _L('Extension non reconnue'); |
|
| 184 | 184 | } |
| 185 | 185 | } elseif ($file and $file['error'] != 0 and isset($file['msg'])) { |
| 186 | 186 | $erreurs['message_erreur'] = $file['msg']; |
@@ -265,7 +265,7 @@ discard block |
||
| 265 | 265 | include_spip('inc/documents'); |
| 266 | 266 | $sources = []; |
| 267 | 267 | foreach (['on', 'off'] as $etat) { |
| 268 | - $logo = 'logo_' . $etat; |
|
| 268 | + $logo = 'logo_'.$etat; |
|
| 269 | 269 | if (isset($_FILES[$logo])) { |
| 270 | 270 | if ($_FILES[$logo]['error'] == 0) { |
| 271 | 271 | $sources[$etat] = $_FILES[$logo]; |
@@ -31,7 +31,7 @@ |
||
| 31 | 31 | foreach ($langues as $l) { |
| 32 | 32 | $res .= "<option value='$l'" |
| 33 | 33 | . ($l == $l_site ? " selected='selected'" : '') |
| 34 | - . '>' . traduire_nom_langue($l) . "</option>\n"; |
|
| 34 | + . '>'.traduire_nom_langue($l)."</option>\n"; |
|
| 35 | 35 | } |
| 36 | 36 | |
| 37 | 37 | $valeurs = [ |
@@ -48,7 +48,7 @@ discard block |
||
| 48 | 48 | include_spip('inc/texte'); // pour aide, couper, lang |
| 49 | 49 | $info = ''; |
| 50 | 50 | if (!need_proxy($t['host'], $http_proxy, $http_noproxy)) { |
| 51 | - $info = '<strong>' . _T('page_pas_proxy') . '</strong><br />'; |
|
| 51 | + $info = '<strong>'._T('page_pas_proxy').'</strong><br />'; |
|
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | // il faut fausser le proxy actuel pour faire le test ! |
@@ -61,14 +61,14 @@ discard block |
||
| 61 | 61 | $GLOBALS['meta']['http_proxy'] = $cur_http_proxy; |
| 62 | 62 | $GLOBALS['meta']['http_noproxy'] = $cur_http_noproxy; |
| 63 | 63 | if ($page) { |
| 64 | - $erreurs['message_ok'] = _T('info_proxy_ok') . "<br />$info\n<tt>" . couper(entites_html($page), 300) . '</tt>'; |
|
| 64 | + $erreurs['message_ok'] = _T('info_proxy_ok')."<br />$info\n<tt>".couper(entites_html($page), 300).'</tt>'; |
|
| 65 | 65 | $erreurs['message_erreur'] = ''; |
| 66 | 66 | } else { |
| 67 | - $erreurs['message_erreur'] = $info . _T( |
|
| 67 | + $erreurs['message_erreur'] = $info._T( |
|
| 68 | 68 | 'info_impossible_lire_page', |
| 69 | 69 | ['test_proxy' => "<tt>$test_proxy</tt>"] |
| 70 | 70 | ) |
| 71 | - . ' <b><tt>' . no_password_proxy_url($http_proxy) . '</tt></b>.' |
|
| 71 | + . ' <b><tt>'.no_password_proxy_url($http_proxy).'</tt></b>.' |
|
| 72 | 72 | . aider('confhttpproxy'); |
| 73 | 73 | } |
| 74 | 74 | } |
@@ -112,23 +112,23 @@ discard block |
||
| 112 | 112 | return false; |
| 113 | 113 | } |
| 114 | 114 | // scheme |
| 115 | - $uri = (!empty($url['scheme'])) ? $url['scheme'] . '://' : ''; |
|
| 115 | + $uri = (!empty($url['scheme'])) ? $url['scheme'].'://' : ''; |
|
| 116 | 116 | // user & pass |
| 117 | 117 | if (!empty($url['user'])) { |
| 118 | - $uri .= $url['user'] . ':' . $url['pass'] . '@'; |
|
| 118 | + $uri .= $url['user'].':'.$url['pass'].'@'; |
|
| 119 | 119 | } |
| 120 | 120 | // host |
| 121 | 121 | $uri .= $url['host']; |
| 122 | 122 | // port |
| 123 | - $port = (!empty($url['port'])) ? ':' . $url['port'] : ''; |
|
| 123 | + $port = (!empty($url['port'])) ? ':'.$url['port'] : ''; |
|
| 124 | 124 | $uri .= $port; |
| 125 | 125 | // path |
| 126 | 126 | $uri .= $url['path']; |
| 127 | 127 | // fragment or query |
| 128 | 128 | if (isset($url['fragment'])) { |
| 129 | - $uri .= '#' . $url['fragment']; |
|
| 129 | + $uri .= '#'.$url['fragment']; |
|
| 130 | 130 | } elseif (isset($url['query'])) { |
| 131 | - $uri .= '?' . $url['query']; |
|
| 131 | + $uri .= '?'.$url['query']; |
|
| 132 | 132 | } |
| 133 | 133 | |
| 134 | 134 | return $uri; |
@@ -96,7 +96,7 @@ |
||
| 96 | 96 | $id_job = job_queue_add('mail', 'Test Envoi des nouveautes', [0], 'genie/'); |
| 97 | 97 | include_spip('inc/queue'); |
| 98 | 98 | queue_schedule([$id_job]); |
| 99 | - $res['message_ok'] .= '<br />' . _T('info_liste_nouveautes_envoyee'); |
|
| 99 | + $res['message_ok'] .= '<br />'._T('info_liste_nouveautes_envoyee'); |
|
| 100 | 100 | } |
| 101 | 101 | |
| 102 | 102 | return $res; |
@@ -145,7 +145,7 @@ discard block |
||
| 145 | 145 | # preparer un lien pour quand redirige_formulaire ne fonctionne pas |
| 146 | 146 | $m = redirige_formulaire($res['redirect']); |
| 147 | 147 | $valeurs['_deja_loge'] = inserer_attribut( |
| 148 | - '<a>' . _T('login_par_ici') . "</a>$m", |
|
| 148 | + '<a>'._T('login_par_ici')."</a>$m", |
|
| 149 | 149 | 'href', |
| 150 | 150 | $res['redirect'] |
| 151 | 151 | ); |
@@ -292,7 +292,7 @@ discard block |
||
| 292 | 292 | function login_autoriser() { |
| 293 | 293 | include_spip('inc/autoriser'); |
| 294 | 294 | if (!autoriser('ecrire')) { |
| 295 | - $h = generer_url_action('logout', 'logout=prive&url=' . urlencode(self())); |
|
| 295 | + $h = generer_url_action('logout', 'logout=prive&url='.urlencode(self())); |
|
| 296 | 296 | |
| 297 | 297 | return [ |
| 298 | 298 | 'message_erreur' => '<h1>' |
@@ -300,7 +300,7 @@ discard block |
||
| 300 | 300 | . '</h1><p>' |
| 301 | 301 | . _T('texte_erreur_visiteur') |
| 302 | 302 | . "</p><p class='retour'>[<a href='$h'>" |
| 303 | - . _T('icone_deconnecter') . '</a>]</p>' |
|
| 303 | + . _T('icone_deconnecter').'</a>]</p>' |
|
| 304 | 304 | ]; |
| 305 | 305 | } |
| 306 | 306 | |
@@ -352,7 +352,7 @@ discard block |
||
| 352 | 352 | // transformer la cible absolue en cible relative |
| 353 | 353 | // pour pas echouer quand la meta adresse_site est foireuse |
| 354 | 354 | if (strncmp($cible, $u = url_de_base(), strlen($u)) == 0) { |
| 355 | - $cible = './' . substr($cible, strlen($u)); |
|
| 355 | + $cible = './'.substr($cible, strlen($u)); |
|
| 356 | 356 | } elseif (tester_url_absolue($cible) and !defined('_AUTORISER_LOGIN_ABS_REDIRECT')) { |
| 357 | 357 | // si c'est une url absolue, refuser la redirection |
| 358 | 358 | // sauf si cette securite est levee volontairement par le webmestre |
@@ -364,7 +364,7 @@ discard block |
||
| 364 | 364 | if ($cible and ($cible != self('&')) and ($cible != self())) { |
| 365 | 365 | $res['redirect'] = $cible; |
| 366 | 366 | $res['message_ok'] = inserer_attribut( |
| 367 | - '<a>' . _T('login_par_ici') . '</a>', |
|
| 367 | + '<a>'._T('login_par_ici').'</a>', |
|
| 368 | 368 | 'href', |
| 369 | 369 | $cible |
| 370 | 370 | ); |
@@ -25,10 +25,10 @@ discard block |
||
| 25 | 25 | if (defined('_DECLARER_CHOIX_DB')) { |
| 26 | 26 | $nom_connect = _DECLARER_CHOIX_DB; |
| 27 | 27 | $n = ''; |
| 28 | - while (in_array($nom_connect . $n, $deja)) { |
|
| 28 | + while (in_array($nom_connect.$n, $deja)) { |
|
| 29 | 29 | $n = ($n ? $n + 1 : 1); |
| 30 | 30 | } |
| 31 | - $nom_connect = $nom_connect . $n; |
|
| 31 | + $nom_connect = $nom_connect.$n; |
|
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | $valeurs = [ |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | |
| 56 | 56 | function liste_serveurs() { |
| 57 | 57 | $options = []; |
| 58 | - $dir = _DIR_RESTREINT . 'req/'; |
|
| 58 | + $dir = _DIR_RESTREINT.'req/'; |
|
| 59 | 59 | $d = opendir($dir); |
| 60 | 60 | if (!$d) { |
| 61 | 61 | return []; |
@@ -63,11 +63,11 @@ discard block |
||
| 63 | 63 | while ($f = readdir($d)) { |
| 64 | 64 | if ( |
| 65 | 65 | (preg_match('/^(.*)[.]php$/', $f, $s)) |
| 66 | - and is_readable($f = $dir . $f) |
|
| 66 | + and is_readable($f = $dir.$f) |
|
| 67 | 67 | ) { |
| 68 | 68 | require_once($f); |
| 69 | 69 | $s = $s[1]; |
| 70 | - $v = 'spip_versions_' . $s; |
|
| 70 | + $v = 'spip_versions_'.$s; |
|
| 71 | 71 | if (function_exists($v) and $v()) { |
| 72 | 72 | $options[$s] = "install_select_type_$s"; |
| 73 | 73 | } else { |
@@ -141,7 +141,7 @@ discard block |
||
| 141 | 141 | |
| 142 | 142 | $link = spip_connect_db($adresse_db, '', $login_db, $pass_db, '@test@', $serveur_db); |
| 143 | 143 | if ($link) { |
| 144 | - $GLOBALS['connexions'][$serveur_db][$GLOBALS['spip_sql_version']] = $GLOBALS['spip_' . $serveur_db . '_functions_' . $GLOBALS['spip_sql_version']]; |
|
| 144 | + $GLOBALS['connexions'][$serveur_db][$GLOBALS['spip_sql_version']] = $GLOBALS['spip_'.$serveur_db.'_functions_'.$GLOBALS['spip_sql_version']]; |
|
| 145 | 145 | $GLOBALS['connexions'][$serveur_db] = $link; |
| 146 | 146 | define('_DECLARER_SERVEUR_DB', $serveur_db); |
| 147 | 147 | define('_DECLARER_ADRESSE_DB', $adresse_db); |
@@ -191,7 +191,7 @@ discard block |
||
| 191 | 191 | $f = preg_replace(',[^\w],', '', $nom_connect); |
| 192 | 192 | if ($f !== $nom_connect) { |
| 193 | 193 | $erreurs['nom_connect'] = _T('erreur_nom_connect_incorrect'); |
| 194 | - } elseif (file_exists(_DIR_CONNECT . $nom_connect . '.php')) { |
|
| 194 | + } elseif (file_exists(_DIR_CONNECT.$nom_connect.'.php')) { |
|
| 195 | 195 | $erreurs['nom_connect'] = _T('erreur_connect_deja_existant'); |
| 196 | 196 | } else { |
| 197 | 197 | define('_DECLARER_NOM_CONNECT', $nom_connect); |
@@ -225,9 +225,9 @@ discard block |
||
| 225 | 225 | '' |
| 226 | 226 | ); |
| 227 | 227 | |
| 228 | - install_fichier_connexion(_DIR_CONNECT . _DECLARER_NOM_CONNECT . '.php', $conn); |
|
| 228 | + install_fichier_connexion(_DIR_CONNECT._DECLARER_NOM_CONNECT.'.php', $conn); |
|
| 229 | 229 | |
| 230 | 230 | return [ |
| 231 | - 'message_ok' => _T('install_connect_ok', ['connect' => '<strong>' . _DECLARER_NOM_CONNECT . '</strong>']) |
|
| 231 | + 'message_ok' => _T('install_connect_ok', ['connect' => '<strong>'._DECLARER_NOM_CONNECT.'</strong>']) |
|
| 232 | 232 | ]; |
| 233 | 233 | } |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | // un checkbox seul de name X non coche n'est pas poste. |
| 41 | 41 | // on verifie le champ X_check qui indique que la checkbox etait presente dans le formulaire. |
| 42 | 42 | foreach (['multi_secteurs'] as $m) { |
| 43 | - if (!is_null(_request($m . '_check'))) { |
|
| 43 | + if (!is_null(_request($m.'_check'))) { |
|
| 44 | 44 | ecrire_meta($m, _request($m) ? 'oui' : 'non'); |
| 45 | 45 | } |
| 46 | 46 | } |
@@ -113,12 +113,12 @@ discard block |
||
| 113 | 113 | . "'>" |
| 114 | 114 | . "<input type='hidden' name='{$name}[]' value='$code_langue'>" // necessaire ... |
| 115 | 115 | . "<input type='checkbox' name='{$name}[]' id='{$name}_$code_langue' value='$code_langue' checked='checked' disabled='disabled' />" |
| 116 | - . "<label for='{$name}_$code_langue'>" . $nom_langue . " <span class='code_langue'>[$code_langue]</span></label>" |
|
| 116 | + . "<label for='{$name}_$code_langue'>".$nom_langue." <span class='code_langue'>[$code_langue]</span></label>" |
|
| 117 | 117 | . '</li>'; |
| 118 | 118 | } |
| 119 | 119 | |
| 120 | 120 | if ($res) { |
| 121 | - $res = "<ul id='langues_bloquees'>" . $res . "</ul><div class='nettoyeur'></div>"; |
|
| 121 | + $res = "<ul id='langues_bloquees'>".$res."</ul><div class='nettoyeur'></div>"; |
|
| 122 | 122 | } |
| 123 | 123 | |
| 124 | 124 | $res .= "<ul id='langues_proposees'>"; |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | . "<label for='{$name}_$code_langue'" |
| 139 | 139 | . ($checked ? " class='on'" : '') |
| 140 | 140 | . '>' |
| 141 | - . $nom_langue . " <span class='code_langue'>[$code_langue]</span></label>" |
|
| 141 | + . $nom_langue." <span class='code_langue'>[$code_langue]</span></label>" |
|
| 142 | 142 | . '</li>'; |
| 143 | 143 | } |
| 144 | 144 | } |