@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | asort($liste_plugins); |
| 66 | 66 | $exposed = urldecode(_request('plugin')); |
| 67 | 67 | |
| 68 | - $block_par_lettre = false;//count($liste_plugins)>10; |
|
| 68 | + $block_par_lettre = false; //count($liste_plugins)>10; |
|
| 69 | 69 | $fast_liste_plugins_actifs = []; |
| 70 | 70 | $fast_liste_plugins_checked = []; |
| 71 | 71 | if (is_array($liste_plugins_actifs)) { |
@@ -90,11 +90,11 @@ discard block |
||
| 90 | 90 | $actif = isset($fast_liste_plugins_actifs[$plug]); |
| 91 | 91 | $checked = isset($fast_liste_plugins_checked[$plug]); |
| 92 | 92 | $block_actif = $block_actif | $actif; |
| 93 | - $expose = ($exposed and ($exposed == $plug or $exposed == $dir_plugins . $plug or $exposed == substr( |
|
| 93 | + $expose = ($exposed and ($exposed == $plug or $exposed == $dir_plugins.$plug or $exposed == substr( |
|
| 94 | 94 | $dir_plugins, |
| 95 | 95 | strlen(_DIR_RACINE) |
| 96 | - ) . $plug)); |
|
| 97 | - $block .= $ligne_plug($url_page, $plug, $checked, $actif, $expose, 'item', $dir_plugins) . "\n"; |
|
| 96 | + ).$plug)); |
|
| 97 | + $block .= $ligne_plug($url_page, $plug, $checked, $actif, $expose, 'item', $dir_plugins)."\n"; |
|
| 98 | 98 | } |
| 99 | 99 | $res .= $block_par_lettre ? affiche_block_initiale($initiale, $block, $block_actif) : $block; |
| 100 | 100 | $class = basename($dir_plugins); |
@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | * @return array |
| 26 | 26 | */ |
| 27 | 27 | function plugins_infos_paquet($desc, $plug = '', $dir_plugins = _DIR_PLUGINS) { |
| 28 | - static $process = [ // tableau constant |
|
| 28 | + static $process = [// tableau constant |
|
| 29 | 29 | 'debut' => 'paquet_debutElement', |
| 30 | 30 | 'fin' => 'paquet_finElement', |
| 31 | 31 | 'text' => 'paquet_textElement' |
@@ -47,8 +47,8 @@ discard block |
||
| 47 | 47 | unset($tree['']); |
| 48 | 48 | } |
| 49 | 49 | |
| 50 | - $tree['slogan'] = $tree['prefix'] . '_slogan'; |
|
| 51 | - $tree['description'] = $tree['prefix'] . '_description'; |
|
| 50 | + $tree['slogan'] = $tree['prefix'].'_slogan'; |
|
| 51 | + $tree['description'] = $tree['prefix'].'_description'; |
|
| 52 | 52 | paquet_readable_files($tree, "$dir_plugins$plug/"); |
| 53 | 53 | if (!$tree['chemin']) { |
| 54 | 54 | $tree['chemin'] = []; |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | // Prendre les messages d'erreur sans les numeros de lignes |
| 81 | 81 | $msg = array_column($vxml->err, 0); |
| 82 | 82 | $t = _T('plugins_erreur', ['plugins' => $plug]); |
| 83 | - array_unshift($msg, $t . " <ul class='erreur_xml'><li>" . reset($msg) . '</li></ul>'); |
|
| 83 | + array_unshift($msg, $t." <ul class='erreur_xml'><li>".reset($msg).'</li></ul>'); |
|
| 84 | 84 | |
| 85 | 85 | return ['erreur' => $msg]; |
| 86 | 86 | } |
@@ -96,9 +96,9 @@ discard block |
||
| 96 | 96 | function paquet_readable_files(&$tree, $dir) { |
| 97 | 97 | $prefix = strtolower($tree['prefix']); |
| 98 | 98 | |
| 99 | - $tree['options'] = (is_readable($dir . $f = ($prefix . '_options.php'))) ? [$f] : []; |
|
| 100 | - $tree['fonctions'] = (is_readable($dir . $f = ($prefix . '_fonctions.php'))) ? [$f] : []; |
|
| 101 | - $tree['install'] = (is_readable($dir . $f = ($prefix . '_administrations.php'))) ? [$f] : []; |
|
| 99 | + $tree['options'] = (is_readable($dir.$f = ($prefix.'_options.php'))) ? [$f] : []; |
|
| 100 | + $tree['fonctions'] = (is_readable($dir.$f = ($prefix.'_fonctions.php'))) ? [$f] : []; |
|
| 101 | + $tree['install'] = (is_readable($dir.$f = ($prefix.'_administrations.php'))) ? [$f] : []; |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | /** |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | $texte = trim($phraseur->versions[$n]['']); |
| 187 | 187 | $phraseur->versions[$n][''] = ''; |
| 188 | 188 | |
| 189 | - $f = 'info_paquet_' . $name; |
|
| 189 | + $f = 'info_paquet_'.$name; |
|
| 190 | 190 | if (function_exists($f)) { |
| 191 | 191 | $f($phraseur, $attrs, $texte); |
| 192 | 192 | } elseif (!$attrs) { |
@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | |
| 39 | 39 | // numerotons les occurences d'un meme prefix |
| 40 | 40 | $versions[$info['prefix']] = isset($versions[$info['prefix']]) ? $versions[$info['prefix']] + 1 : ''; |
| 41 | - $id = $info['prefix'] . $versions[$info['prefix']]; |
|
| 41 | + $id = $info['prefix'].$versions[$info['prefix']]; |
|
| 42 | 42 | |
| 43 | 43 | $class = $class_li; |
| 44 | 44 | $class .= $actif ? ' actif' : ''; |
@@ -55,15 +55,15 @@ discard block |
||
| 55 | 55 | $prefix = $info['prefix']; |
| 56 | 56 | $dir = "$dir_plugins$plug_file/lang/$prefix"; |
| 57 | 57 | $desc = plugin_propre($info['description'], $dir); |
| 58 | - $url_stat = parametre_url($url_page, 'plugin', $dir_plugins . $plug_file); |
|
| 58 | + $url_stat = parametre_url($url_page, 'plugin', $dir_plugins.$plug_file); |
|
| 59 | 59 | |
| 60 | - $s .= "<strong class='nom'>" . typo($info['nom']) . '</strong>'; |
|
| 61 | - $s .= " <span class='version'>" . $info['version'] . '</span>'; |
|
| 62 | - $s .= " <span class='etat'> - " . plugin_etat_en_clair($info['etat']) . '</span>'; |
|
| 60 | + $s .= "<strong class='nom'>".typo($info['nom']).'</strong>'; |
|
| 61 | + $s .= " <span class='version'>".$info['version'].'</span>'; |
|
| 62 | + $s .= " <span class='etat'> - ".plugin_etat_en_clair($info['etat']).'</span>'; |
|
| 63 | 63 | $s .= '</div>'; |
| 64 | 64 | |
| 65 | 65 | if ($erreur) { |
| 66 | - $s .= "<div class='erreur'>" . join('<br >', $info['erreur']) . '</div>'; |
|
| 66 | + $s .= "<div class='erreur'>".join('<br >', $info['erreur']).'</div>'; |
|
| 67 | 67 | } |
| 68 | 68 | |
| 69 | 69 | $s .= '</li>'; |
@@ -37,7 +37,7 @@ discard block |
||
| 37 | 37 | static $filecache = ''; |
| 38 | 38 | |
| 39 | 39 | if ($cache === '') { |
| 40 | - $filecache = _DIR_TMP . 'plugin_xml_cache.gz'; |
|
| 40 | + $filecache = _DIR_TMP.'plugin_xml_cache.gz'; |
|
| 41 | 41 | if (is_file($filecache)) { |
| 42 | 42 | lire_fichier($filecache, $contenu); |
| 43 | 43 | $cache = unserialize($contenu); |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | if (isset($ret['prefix']) and $ret['prefix'] == 'spip') { |
| 129 | 129 | $ret['procure']['php'] = ['nom' => 'php', 'version' => phpversion()]; |
| 130 | 130 | foreach (get_loaded_extensions() as $ext) { |
| 131 | - $ret['procure']['php:' . $ext] = ['nom' => 'php:' . $ext, 'version' => phpversion($ext)]; |
|
| 131 | + $ret['procure']['php:'.$ext] = ['nom' => 'php:'.$ext, 'version' => phpversion($ext)]; |
|
| 132 | 132 | } |
| 133 | 133 | } |
| 134 | 134 | $diff = ($ret != $pcache); |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | $l = ''; |
| 54 | 54 | if ( |
| 55 | 55 | $primary = id_table_objet($objet) |
| 56 | - and $trouver_table($l = $table_sql . '_liens') |
|
| 56 | + and $trouver_table($l = $table_sql.'_liens') |
|
| 57 | 57 | and !preg_match(',[^\w],', $primary) |
| 58 | 58 | and !preg_match(',[^\w],', $l) |
| 59 | 59 | ) { |
@@ -212,7 +212,7 @@ discard block |
||
| 212 | 212 | * @return int |
| 213 | 213 | */ |
| 214 | 214 | function objet_optimiser_liens($objets_source, $objets_lies) { |
| 215 | - spip_log('objet_optimiser_liens : ' . json_encode($objets_source) . ', ' . json_encode($objets_lies), 'genie' . _LOG_DEBUG); |
|
| 215 | + spip_log('objet_optimiser_liens : '.json_encode($objets_source).', '.json_encode($objets_lies), 'genie'._LOG_DEBUG); |
|
| 216 | 216 | return objet_traiter_liaisons('lien_optimise', $objets_source, $objets_lies); |
| 217 | 217 | } |
| 218 | 218 | |
@@ -446,7 +446,7 @@ discard block |
||
| 446 | 446 | $where_meme_lien = implode(' AND ', $where_meme_lien); |
| 447 | 447 | // on decale les liens de rang_lien>=la valeur inseree pour faire la place |
| 448 | 448 | // sauf sur le meme lien avec un role eventuellement different |
| 449 | - $w = lien_rang_where($table_lien, $primary, $id, $objet, $id_objet, ['rang_lien>=' . intval($insertions['rang_lien']), "NOT($where_meme_lien)"]); |
|
| 449 | + $w = lien_rang_where($table_lien, $primary, $id, $objet, $id_objet, ['rang_lien>='.intval($insertions['rang_lien']), "NOT($where_meme_lien)"]); |
|
| 450 | 450 | sql_update($table_lien, ['rang_lien' => 'rang_lien+1'], $w); |
| 451 | 451 | } |
| 452 | 452 | |
@@ -511,7 +511,7 @@ discard block |
||
| 511 | 511 | $rang = 1; |
| 512 | 512 | foreach ($liens as $lien) { |
| 513 | 513 | if (empty($deja_reordonne[$lien[$primary]][$lien['objet']][$lien['id_objet']])) { |
| 514 | - $where = lien_where($primary, $lien[$primary], $lien['objet'], $lien['id_objet'], ['rang_lien!=' . intval($rang)]); |
|
| 514 | + $where = lien_where($primary, $lien[$primary], $lien['objet'], $lien['id_objet'], ['rang_lien!='.intval($rang)]); |
|
| 515 | 515 | sql_updateq($table_lien, ['rang_lien' => $rang], $where); |
| 516 | 516 | |
| 517 | 517 | if (empty($deja_reordonne[$lien[$primary]])) { |
@@ -587,7 +587,7 @@ discard block |
||
| 587 | 587 | addslashes($primary), |
| 588 | 588 | array_map('intval', $id_source), |
| 589 | 589 | $not |
| 590 | - ) : addslashes($primary) . ($not ? '<>' : '=') . intval($id_source)); |
|
| 590 | + ) : addslashes($primary).($not ? '<>' : '=').intval($id_source)); |
|
| 591 | 591 | } elseif ($not) { |
| 592 | 592 | $where[] = '0=1'; |
| 593 | 593 | } // idiot mais quand meme |
@@ -599,14 +599,14 @@ discard block |
||
| 599 | 599 | } |
| 600 | 600 | |
| 601 | 601 | if ($objet !== '*') { |
| 602 | - $where[] = 'objet=' . sql_quote($objet); |
|
| 602 | + $where[] = 'objet='.sql_quote($objet); |
|
| 603 | 603 | } |
| 604 | 604 | if ($id_objet !== '*') { |
| 605 | 605 | $where[] = (is_array($id_objet) ? sql_in( |
| 606 | 606 | 'id_objet', |
| 607 | 607 | array_map('intval', $id_objet), |
| 608 | 608 | $not |
| 609 | - ) : 'id_objet' . ($not ? '<>' : '=') . intval($id_objet)); |
|
| 609 | + ) : 'id_objet'.($not ? '<>' : '=').intval($id_objet)); |
|
| 610 | 610 | } elseif ($not) { |
| 611 | 611 | $where[] = '0=1'; |
| 612 | 612 | } // idiot mais quand meme |
@@ -627,7 +627,7 @@ discard block |
||
| 627 | 627 | function lien_rang_where($table_lien, $primary, $id_source, $objet, $id_objet, $cond = []) { |
| 628 | 628 | |
| 629 | 629 | // si on veut compter les rangs autrement que le core ne le fait par defaut, fournir le where adhoc |
| 630 | - if (function_exists($f = 'lien_rang_where_' . $table_lien)) { |
|
| 630 | + if (function_exists($f = 'lien_rang_where_'.$table_lien)) { |
|
| 631 | 631 | return $f($primary, $id_source, $objet, $id_objet, $cond); |
| 632 | 632 | } |
| 633 | 633 | |
@@ -792,8 +792,8 @@ discard block |
||
| 792 | 792 | // il faut les eliminier en repetant la condition dans le where L.objet='xxx' |
| 793 | 793 | "$table_lien AS L |
| 794 | 794 | LEFT JOIN $spip_table_objet AS O |
| 795 | - ON (O.$id_table_objet=L.id_objet AND L.objet=" . sql_quote($type) . ')', |
|
| 796 | - 'L.objet=' . sql_quote($type) . " AND O.$id_table_objet IS NULL" |
|
| 795 | + ON (O.$id_table_objet=L.id_objet AND L.objet=".sql_quote($type).')', |
|
| 796 | + 'L.objet='.sql_quote($type)." AND O.$id_table_objet IS NULL" |
|
| 797 | 797 | ); |
| 798 | 798 | // sur une cle primaire composee, pas d'autres solutions que de virer un a un |
| 799 | 799 | while ($row = sql_fetch($res)) { |
@@ -802,13 +802,13 @@ discard block |
||
| 802 | 802 | } |
| 803 | 803 | $e = sql_delete( |
| 804 | 804 | $table_lien, |
| 805 | - ["$primary=" . $row['id'], 'id_objet=' . $row['id_objet'], 'objet=' . sql_quote($type)] |
|
| 805 | + ["$primary=".$row['id'], 'id_objet='.$row['id_objet'], 'objet='.sql_quote($type)] |
|
| 806 | 806 | ); |
| 807 | 807 | if ($e != false) { |
| 808 | 808 | $dels += $e; |
| 809 | 809 | spip_log( |
| 810 | - 'lien_optimise: Entree ' . $row['id'] . '/' . $row['id_objet'] . "/$type supprimee dans la table $table_lien", |
|
| 811 | - 'genie' . _LOG_INFO_IMPORTANTE |
|
| 810 | + 'lien_optimise: Entree '.$row['id'].'/'.$row['id_objet']."/$type supprimee dans la table $table_lien", |
|
| 811 | + 'genie'._LOG_INFO_IMPORTANTE |
|
| 812 | 812 | ); |
| 813 | 813 | } |
| 814 | 814 | } |
@@ -912,7 +912,7 @@ discard block |
||
| 912 | 912 | // sauf sur le meme lien avec un role eventuellement different |
| 913 | 913 | $where_meme_lien = lien_where($primary, $id, $objet, $id_objet); |
| 914 | 914 | $where_meme_lien = implode(' AND ', $where_meme_lien); |
| 915 | - $w = lien_rang_where($table_lien, $primary, $id, $objet, $id_objet, ['rang_lien>=' . intval($qualif['rang_lien']), "NOT($where_meme_lien)"]); |
|
| 915 | + $w = lien_rang_where($table_lien, $primary, $id, $objet, $id_objet, ['rang_lien>='.intval($qualif['rang_lien']), "NOT($where_meme_lien)"]); |
|
| 916 | 916 | sql_update($table_lien, ['rang_lien' => 'rang_lien+1'], $w); |
| 917 | 917 | } |
| 918 | 918 | // tous les liens de même rôle recoivent le rang indiqué aussi |
@@ -1004,7 +1004,7 @@ discard block |
||
| 1004 | 1004 | */ |
| 1005 | 1005 | function lien_propage_date_modif($objet, $ids) { |
| 1006 | 1006 | static $done = []; |
| 1007 | - $hash = md5($objet . serialize($ids)); |
|
| 1007 | + $hash = md5($objet.serialize($ids)); |
|
| 1008 | 1008 | |
| 1009 | 1009 | // sql_updateq, peut être un rien lent. |
| 1010 | 1010 | // On évite de l'appeler 2 fois sur les mêmes choses |
@@ -1020,7 +1020,7 @@ discard block |
||
| 1020 | 1020 | and isset($desc['field']['date_modif']) |
| 1021 | 1021 | ) { |
| 1022 | 1022 | $primary = id_table_objet($objet); |
| 1023 | - $where = (is_array($ids) ? sql_in($primary, array_map('intval', $ids)) : "$primary=" . intval($ids)); |
|
| 1023 | + $where = (is_array($ids) ? sql_in($primary, array_map('intval', $ids)) : "$primary=".intval($ids)); |
|
| 1024 | 1024 | sql_updateq($table, ['date_modif' => date('Y-m-d H:i:s')], $where); |
| 1025 | 1025 | } |
| 1026 | 1026 | |
@@ -53,10 +53,10 @@ discard block |
||
| 53 | 53 | |
| 54 | 54 | if ($compil_info) { |
| 55 | 55 | $contexte_compil = [ |
| 56 | - $trace[0]['file'],// sourcefile |
|
| 56 | + $trace[0]['file'], // sourcefile |
|
| 57 | 57 | '', //nom |
| 58 | - (isset($trace[1]) ? $trace[1]['function'] . "(){\n" : '') |
|
| 59 | - . $trace[0]['function'] . '();' |
|
| 58 | + (isset($trace[1]) ? $trace[1]['function']."(){\n" : '') |
|
| 59 | + . $trace[0]['function'].'();' |
|
| 60 | 60 | . (isset($trace[1]) ? "\n}" : ''), //id_boucle |
| 61 | 61 | $trace[0]['line'], // ligne |
| 62 | 62 | $GLOBALS['spip_lang'], // lang |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | return $contexte_compil; |
| 66 | 66 | } |
| 67 | 67 | |
| 68 | - $message = count($trace) ? $trace[0]['file'] . ' L' . $trace[0]['line'] : ''; |
|
| 68 | + $message = count($trace) ? $trace[0]['file'].' L'.$trace[0]['line'] : ''; |
|
| 69 | 69 | $f = []; |
| 70 | 70 | while (count($trace) and $t = array_shift($trace)) { |
| 71 | 71 | if (in_array($t['function'], ['include_once', 'include_spip', 'find_in_path'])) { |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | $f[] = $t['function']; |
| 75 | 75 | } |
| 76 | 76 | if (count($f)) { |
| 77 | - $message .= ' [' . implode('(),', $f) . '()]'; |
|
| 77 | + $message .= ' ['.implode('(),', $f).'()]'; |
|
| 78 | 78 | } |
| 79 | 79 | |
| 80 | 80 | return $message; |
@@ -266,8 +266,8 @@ discard block |
||
| 266 | 266 | } |
| 267 | 267 | // le debug, c'est pour ce qui a ete produit par le compilateur |
| 268 | 268 | if (isset($GLOBALS['debug']['aucasou'])) { |
| 269 | - list($table, $id, ) = $GLOBALS['debug']['aucasou']; |
|
| 270 | - $nom = $GLOBALS['debug_objets']['courant'] . $id; |
|
| 269 | + list($table, $id,) = $GLOBALS['debug']['aucasou']; |
|
| 270 | + $nom = $GLOBALS['debug_objets']['courant'].$id; |
|
| 271 | 271 | $GLOBALS['debug_objets']['requete'][$nom] = $query; |
| 272 | 272 | } |
| 273 | 273 | $res = $f($select, $from, $where, $groupby, $orderby, $limit, $having, $serveur, true); |
@@ -1144,7 +1144,7 @@ discard block |
||
| 1144 | 1144 | // la globale n'est remplie qu'apres l'appel de sql_serveur. |
| 1145 | 1145 | if ($spip == null) { |
| 1146 | 1146 | $connexion = $GLOBALS['connexions'][$serveur ? strtolower($serveur) : 0]; |
| 1147 | - $spip = $connexion['prefixe'] . '\_%'; |
|
| 1147 | + $spip = $connexion['prefixe'].'\_%'; |
|
| 1148 | 1148 | } |
| 1149 | 1149 | |
| 1150 | 1150 | return $f($spip, $serveur, $option !== false); |
@@ -2034,7 +2034,7 @@ discard block |
||
| 2034 | 2034 | } |
| 2035 | 2035 | |
| 2036 | 2036 | // sql_quote produit une chaine dans tous les cas |
| 2037 | - $valeurs = array_filter($valeurs, function ($v) { |
|
| 2037 | + $valeurs = array_filter($valeurs, function($v) { |
|
| 2038 | 2038 | return !is_array($v); |
| 2039 | 2039 | }); |
| 2040 | 2040 | $valeurs = array_unique($valeurs); |
@@ -2261,9 +2261,9 @@ discard block |
||
| 2261 | 2261 | $jour = 0; |
| 2262 | 2262 | } |
| 2263 | 2263 | |
| 2264 | - return sprintf('%04u', $annee) . '-' . sprintf('%02u', $mois) . '-' |
|
| 2265 | - . sprintf('%02u', $jour) . ' ' . sprintf('%02u', $h) . ':' |
|
| 2266 | - . sprintf('%02u', $m) . ':' . sprintf('%02u', $s); |
|
| 2264 | + return sprintf('%04u', $annee).'-'.sprintf('%02u', $mois).'-' |
|
| 2265 | + . sprintf('%02u', $jour).' '.sprintf('%02u', $h).':' |
|
| 2266 | + . sprintf('%02u', $m).':'.sprintf('%02u', $s); |
|
| 2267 | 2267 | } |
| 2268 | 2268 | |
| 2269 | 2269 | |
@@ -2325,7 +2325,7 @@ discard block |
||
| 2325 | 2325 | */ |
| 2326 | 2326 | function prefixer_table_spip($table, $prefixe) { |
| 2327 | 2327 | if ($prefixe) { |
| 2328 | - $table = preg_replace('/^spip_/', $prefixe . '_', $table); |
|
| 2328 | + $table = preg_replace('/^spip_/', $prefixe.'_', $table); |
|
| 2329 | 2329 | } |
| 2330 | 2330 | return $table; |
| 2331 | 2331 | } |
@@ -124,7 +124,7 @@ discard block |
||
| 124 | 124 | $select = true |
| 125 | 125 | ) { |
| 126 | 126 | if (!is_string($defaut)) { |
| 127 | - $defaut = '@$Pile[0][\'' . strtolower($nom_champ) . '\']'; |
|
| 127 | + $defaut = '@$Pile[0][\''.strtolower($nom_champ).'\']'; |
|
| 128 | 128 | } |
| 129 | 129 | |
| 130 | 130 | $idb_origine = $idb; |
@@ -157,7 +157,7 @@ discard block |
||
| 157 | 157 | } |
| 158 | 158 | // renseigner la boucle source de ce champ pour les traitements |
| 159 | 159 | $boucles[$idb_origine]->index_champ[$nom_champ_origine] = $idb; |
| 160 | - $champ = '$Pile[$SP' . ($i ? "-$i" : '') . '][\'' . $c . '\']'; |
|
| 160 | + $champ = '$Pile[$SP'.($i ? "-$i" : '').'][\''.$c.'\']'; |
|
| 161 | 161 | if (!$joker) { |
| 162 | 162 | return index_compose($conditionnel, $champ); |
| 163 | 163 | } |
@@ -198,7 +198,7 @@ discard block |
||
| 198 | 198 | function index_compose($conditionnel, $defaut) { |
| 199 | 199 | while ($c = array_pop($conditionnel)) { |
| 200 | 200 | // si on passe defaut = '', ne pas générer d'erreur de compilation. |
| 201 | - $defaut = "($c:(" . ($defaut ? $defaut : "''") . '))'; |
|
| 201 | + $defaut = "($c:(".($defaut ? $defaut : "''").'))'; |
|
| 202 | 202 | } |
| 203 | 203 | |
| 204 | 204 | return $defaut; |
@@ -245,7 +245,7 @@ discard block |
||
| 245 | 245 | if (!$r) { |
| 246 | 246 | $joker = false; // indiquer a l'appelant |
| 247 | 247 | # continuer pour chercher l'erreur suivante |
| 248 | - return ["'#" . $r . ':' . $nom_champ . "'", '']; |
|
| 248 | + return ["'#".$r.':'.$nom_champ."'", '']; |
|
| 249 | 249 | } |
| 250 | 250 | |
| 251 | 251 | $desc = $boucles[$idb]->show; |
@@ -348,8 +348,8 @@ discard block |
||
| 348 | 348 | $t = $index_exception_derogatoire($boucle, $desc, $nom_champ, $excep); |
| 349 | 349 | } |
| 350 | 350 | if ($t == null) { |
| 351 | - list($e, $x) = $excep; #PHP4 affecte de gauche a droite |
|
| 352 | - $excep = $x; #PHP5 de droite a gauche ! |
|
| 351 | + list($e, $x) = $excep; #PHP4 affecte de gauche a droite |
|
| 352 | + $excep = $x; #PHP5 de droite a gauche ! |
|
| 353 | 353 | $j = $trouver_table($e, $boucle->sql_serveur); |
| 354 | 354 | if (!$j) { |
| 355 | 355 | return ['', '']; |
@@ -361,7 +361,7 @@ discard block |
||
| 361 | 361 | $l = (preg_split('/\s*,\s*/', $k)); |
| 362 | 362 | $k = $desc['key']['PRIMARY KEY']; |
| 363 | 363 | if (!in_array($k, $l)) { |
| 364 | - spip_log("jointure impossible $e " . join(',', $l)); |
|
| 364 | + spip_log("jointure impossible $e ".join(',', $l)); |
|
| 365 | 365 | |
| 366 | 366 | return ['', '']; |
| 367 | 367 | } |
@@ -377,7 +377,7 @@ discard block |
||
| 377 | 377 | // demander a SQL de gerer le synonyme |
| 378 | 378 | // ca permet que excep soit dynamique (Cedric, 2/3/06) |
| 379 | 379 | if ($excep != $nom_champ) { |
| 380 | - $excep .= ' AS ' . $nom_champ; |
|
| 380 | + $excep .= ' AS '.$nom_champ; |
|
| 381 | 381 | } |
| 382 | 382 | |
| 383 | 383 | return ["$t.$excep", $nom_champ]; |
@@ -611,7 +611,7 @@ discard block |
||
| 611 | 611 | join(',', $collecte), |
| 612 | 612 | ($collecte ? $param : substr($param, 1)), # virer la virgule |
| 613 | 613 | memoriser_contexte_compil($p), |
| 614 | - (!$supp ? '' : (', ' . join(',', $supp))) |
|
| 614 | + (!$supp ? '' : (', '.join(',', $supp))) |
|
| 615 | 615 | ); |
| 616 | 616 | |
| 617 | 617 | $p->interdire_scripts = false; |
@@ -709,7 +709,7 @@ discard block |
||
| 709 | 709 | $nom = $p->id_boucle; |
| 710 | 710 | |
| 711 | 711 | if ($nom and trouver_nom_serveur_distant($p)) { |
| 712 | - spip_log($nom . ':' . $p->nom_champ . ' ' . _T('zbug_distant_interdit')); |
|
| 712 | + spip_log($nom.':'.$p->nom_champ.' '._T('zbug_distant_interdit')); |
|
| 713 | 713 | |
| 714 | 714 | return false; |
| 715 | 715 | } |
@@ -795,7 +795,7 @@ discard block |
||
| 795 | 795 | (strpos($ps, 'typo') !== false) |
| 796 | 796 | ) |
| 797 | 797 | ) { |
| 798 | - $ps = 'traiter_doublons_documents($doublons, ' . $ps . ')'; |
|
| 798 | + $ps = 'traiter_doublons_documents($doublons, '.$ps.')'; |
|
| 799 | 799 | } |
| 800 | 800 | |
| 801 | 801 | // La protection des champs par |safehtml est assuree par les extensions |
@@ -916,7 +916,7 @@ discard block |
||
| 916 | 916 | function compose_filtres_args($p, $args, $sep) { |
| 917 | 917 | $arglist = ''; |
| 918 | 918 | foreach ($args as $arg) { |
| 919 | - $arglist .= $sep . |
|
| 919 | + $arglist .= $sep. |
|
| 920 | 920 | calculer_liste($arg, $p->descr, $p->boucles, $p->id_boucle); |
| 921 | 921 | } |
| 922 | 922 | |
@@ -967,7 +967,7 @@ discard block |
||
| 967 | 967 | while ($b != '') { |
| 968 | 968 | foreach ($p->boucles[$b]->criteres as $critere) { |
| 969 | 969 | if ($critere->op == $motif) { |
| 970 | - $p->code = '$Pile[$SP' . (($n == 0) ? '' : "-$n") . |
|
| 970 | + $p->code = '$Pile[$SP'.(($n == 0) ? '' : "-$n"). |
|
| 971 | 971 | "]['$champ']"; |
| 972 | 972 | $b = ''; |
| 973 | 973 | break 2; |
@@ -995,6 +995,6 @@ discard block |
||
| 995 | 995 | */ |
| 996 | 996 | function zbug_presenter_champ($p, $champ = '') { |
| 997 | 997 | $balise = $champ ? $champ : $p->nom_champ; |
| 998 | - $explicite = $p->nom_boucle ? $p->nom_boucle . ':' : ''; |
|
| 998 | + $explicite = $p->nom_boucle ? $p->nom_boucle.':' : ''; |
|
| 999 | 999 | return "#{$explicite}{$balise}"; |
| 1000 | 1000 | } |
@@ -39,12 +39,12 @@ discard block |
||
| 39 | 39 | // on renvoi un 401 qui fait echouer la requete ajax silencieusement |
| 40 | 40 | if (!autoriser('ecrire')) { |
| 41 | 41 | $retour = |
| 42 | - '<ul class="deroulant__sous-menu" data-profondeur="1">' . |
|
| 43 | - '<li class="deroulant__item deroulant__item_plan plan_site" data-profondeur="1">' . |
|
| 44 | - '<a class="deroulant__lien" href="' . generer_url_ecrire('accueil') . '" data-profondeur="1">' . |
|
| 45 | - '<span class="libelle">' . _T('public:lien_connecter') . '</span>' . |
|
| 46 | - '</a>' . |
|
| 47 | - '</li>' . |
|
| 42 | + '<ul class="deroulant__sous-menu" data-profondeur="1">'. |
|
| 43 | + '<li class="deroulant__item deroulant__item_plan plan_site" data-profondeur="1">'. |
|
| 44 | + '<a class="deroulant__lien" href="'.generer_url_ecrire('accueil').'" data-profondeur="1">'. |
|
| 45 | + '<span class="libelle">'._T('public:lien_connecter').'</span>'. |
|
| 46 | + '</a>'. |
|
| 47 | + '</li>'. |
|
| 48 | 48 | '</ul>'; |
| 49 | 49 | include_spip('inc/actions'); |
| 50 | 50 | ajax_retour($retour); |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | if ($date = intval(_request('date'))) { |
| 55 | - header('Last-Modified: ' . gmdate('D, d M Y H:i:s', $date) . ' GMT'); |
|
| 55 | + header('Last-Modified: '.gmdate('D, d M Y H:i:s', $date).' GMT'); |
|
| 56 | 56 | } |
| 57 | 57 | |
| 58 | 58 | $r = gen_liste_rubriques(); |
@@ -62,7 +62,7 @@ discard block |
||
| 62 | 62 | and !strstr($_SERVER['SERVER_SOFTWARE'], 'IIS/') |
| 63 | 63 | ) { |
| 64 | 64 | include_spip('inc/headers'); |
| 65 | - header('Content-Type: text/html; charset=' . $GLOBALS['meta']['charset']); |
|
| 65 | + header('Content-Type: text/html; charset='.$GLOBALS['meta']['charset']); |
|
| 66 | 66 | http_response_code(304); |
| 67 | 67 | exit; |
| 68 | 68 | } else { |
@@ -85,8 +85,8 @@ discard block |
||
| 85 | 85 | **/ |
| 86 | 86 | function menu_rubriques($complet = true) { |
| 87 | 87 | $ret = '<li class="deroulant__item deroulant__item_tout toutsite" data-profondeur="1">' |
| 88 | - . '<a class="deroulant__lien" href="' . generer_url_ecrire('plan') . '" data-profondeur="1">' |
|
| 89 | - . '<span class="libelle">' . _T('info_tout_site') . '</span>' |
|
| 88 | + . '<a class="deroulant__lien" href="'.generer_url_ecrire('plan').'" data-profondeur="1">' |
|
| 89 | + . '<span class="libelle">'._T('info_tout_site').'</span>' |
|
| 90 | 90 | . '</a>' |
| 91 | 91 | . '</li>'; |
| 92 | 92 | |
@@ -145,8 +145,8 @@ discard block |
||
| 145 | 145 | static $zmax = 6; |
| 146 | 146 | $profondeur_next = $profondeur + 1; |
| 147 | 147 | |
| 148 | - $nav = '<a class="deroulant__lien" href="' . generer_url_entite($id_rubrique, 'rubrique', '', '', false) . "\" data-profondeur=\"$profondeur\">" |
|
| 149 | - . '<span class="libelle">' . supprimer_tags(preg_replace(',[\x00-\x1f]+,', ' ', $titre_rubrique)) . '</span>' |
|
| 148 | + $nav = '<a class="deroulant__lien" href="'.generer_url_entite($id_rubrique, 'rubrique', '', '', false)."\" data-profondeur=\"$profondeur\">" |
|
| 149 | + . '<span class="libelle">'.supprimer_tags(preg_replace(',[\x00-\x1f]+,', ' ', $titre_rubrique)).'</span>' |
|
| 150 | 150 | . "</a>\n"; |
| 151 | 151 | |
| 152 | 152 | // Limiter volontairement le nombre de sous-menus |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | if ($change_session == 'oui') { |
| 60 | 60 | $session = charger_fonction('session', 'inc'); |
| 61 | 61 | $session(true); |
| 62 | - spip_log('statut 204 pour ' . $_SERVER['REQUEST_URI']); |
|
| 62 | + spip_log('statut 204 pour '.$_SERVER['REQUEST_URI']); |
|
| 63 | 63 | http_response_code(204); // No Content |
| 64 | 64 | return; |
| 65 | 65 | } |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | _T('info_connexion_refusee'), |
| 80 | 80 | _T('login_login_pass_incorrect'), |
| 81 | 81 | _T('login_retour_site'), |
| 82 | - 'url=' . rawurlencode($redirect), |
|
| 82 | + 'url='.rawurlencode($redirect), |
|
| 83 | 83 | _T('login_nouvelle_tentative'), |
| 84 | 84 | (strpos($url, _DIR_RESTREINT_ABS) !== false) |
| 85 | 85 | ); |