@@ -27,7 +27,7 @@ |
||
| 27 | 27 | { |
| 28 | 28 | $ok = false; |
| 29 | 29 | if (!spip_connect()) |
| 30 | - $message = _T('titre_probleme_technique'); |
|
| 30 | + $message = _T('titre_probleme_technique'); |
|
| 31 | 31 | else { |
| 32 | 32 | $version_sql = sql_version(); |
| 33 | 33 | if (!$version_sql) |
@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | // http://doc.spip.org/@exec_puce_statut_dist |
| 18 | 18 | function exec_puce_statut_dist() |
| 19 | 19 | { |
| 20 | - exec_puce_statut_args(_request('id'), _request('type')); |
|
| 20 | + exec_puce_statut_args(_request('id'), _request('type')); |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // http://doc.spip.org/@exec_puce_statut_args |
@@ -42,6 +42,6 @@ discard block |
||
| 42 | 42 | $statut = 'prop'; // arbitraire |
| 43 | 43 | } |
| 44 | 44 | $puce_statut = charger_fonction('puce_statut', 'inc'); |
| 45 | - ajax_retour($puce_statut($id,$statut,$id_rubrique,$type, true)); |
|
| 45 | + ajax_retour($puce_statut($id, $statut, $id_rubrique, $type, true)); |
|
| 46 | 46 | } |
| 47 | 47 | ?> |
@@ -20,13 +20,13 @@ discard block |
||
| 20 | 20 | * deprecie, ne plus utiliser |
| 21 | 21 | * |
| 22 | 22 | */ |
| 23 | -function exec_fond_monobloc_dist(){ |
|
| 23 | +function exec_fond_monobloc_dist() { |
|
| 24 | 24 | |
| 25 | 25 | // pas d'autorisation |
| 26 | 26 | // c'est au fond de les gerer avec #AUTORISER, et de renvoyer un fond vide le cas echeant |
| 27 | 27 | // qui declenchera un minipres acces interdit |
| 28 | 28 | $exec = _request('exec'); |
| 29 | - $fond = trim(recuperer_fond("prive/exec/$exec",$_REQUEST)); |
|
| 29 | + $fond = trim(recuperer_fond("prive/exec/$exec", $_REQUEST)); |
|
| 30 | 30 | if (!$fond) { |
| 31 | 31 | include_spip('inc/minipres'); |
| 32 | 32 | echo minipres(); |
@@ -38,33 +38,33 @@ discard block |
||
| 38 | 38 | $extra = ""; |
| 39 | 39 | |
| 40 | 40 | // recuperer le titre dans le premier hn de la page |
| 41 | - if (preg_match(",<h[1-6][^>]*>(.+)</h[1-6]>,Uims",$fond,$match)){ |
|
| 41 | + if (preg_match(",<h[1-6][^>]*>(.+)</h[1-6]>,Uims", $fond, $match)) { |
|
| 42 | 42 | $titre = $match[1]; |
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | // recuperer la hierarchie (au-dessus du contenu) |
| 46 | - if (preg_match(",<!--#hierarchie-->.+<!--/#hierarchie-->,Uims",$fond,$match)){ |
|
| 46 | + if (preg_match(",<!--#hierarchie-->.+<!--/#hierarchie-->,Uims", $fond, $match)) { |
|
| 47 | 47 | $hierarchie = $match[0]; |
| 48 | - $fond = str_replace($hierarchie,"",$fond); |
|
| 48 | + $fond = str_replace($hierarchie, "", $fond); |
|
| 49 | 49 | } |
| 50 | 50 | |
| 51 | 51 | // recuperer la navigation (colonne de gauche) |
| 52 | - if (preg_match(",<!--#navigation-->.+<!--/#navigation-->,Uims",$fond,$match)){ |
|
| 52 | + if (preg_match(",<!--#navigation-->.+<!--/#navigation-->,Uims", $fond, $match)) { |
|
| 53 | 53 | $navigation = $match[0]; |
| 54 | - $fond = str_replace($navigation,"",$fond); |
|
| 54 | + $fond = str_replace($navigation, "", $fond); |
|
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | // recuperer les extras (colonne de droite) |
| 58 | - if (preg_match(",<!--#extra-->.+<!--/#extra-->,Uims",$fond,$match)){ |
|
| 58 | + if (preg_match(",<!--#extra-->.+<!--/#extra-->,Uims", $fond, $match)) { |
|
| 59 | 59 | $extra = $match[0]; |
| 60 | - $fond = str_replace($extra,"",$fond); |
|
| 60 | + $fond = str_replace($extra, "", $fond); |
|
| 61 | 61 | } |
| 62 | 62 | |
| 63 | 63 | include_spip('inc/presentation'); // alleger les inclusions avec un inc/presentation_mini |
| 64 | - $commencer_page = charger_fonction('commencer_page','inc'); |
|
| 64 | + $commencer_page = charger_fonction('commencer_page', 'inc'); |
|
| 65 | 65 | echo $commencer_page($titre); |
| 66 | 66 | |
| 67 | - if ($hierarchie){ |
|
| 67 | + if ($hierarchie) { |
|
| 68 | 68 | echo debut_grand_cadre(true); |
| 69 | 69 | echo pipeline( |
| 70 | 70 | 'affiche_hierarchie', |
@@ -78,27 +78,27 @@ discard block |
||
| 78 | 78 | echo fin_grand_cadre(true); |
| 79 | 79 | } |
| 80 | 80 | |
| 81 | - echo debut_gauche("exec_$exec",true); |
|
| 81 | + echo debut_gauche("exec_$exec", true); |
|
| 82 | 82 | |
| 83 | 83 | $contexte = array('exec'=>$exec); |
| 84 | - if ($objet_exec = trouver_objet_exec($exec)){ |
|
| 84 | + if ($objet_exec = trouver_objet_exec($exec)) { |
|
| 85 | 85 | $id = $objet_exec['id_table_objet']; |
| 86 | 86 | if (_request($id)) |
| 87 | 87 | $contexte[$id] = _request($id); |
| 88 | 88 | } |
| 89 | 89 | |
| 90 | 90 | echo $navigation; |
| 91 | - echo pipeline('affiche_gauche',array('args'=>$contexte,'data'=>'')); |
|
| 91 | + echo pipeline('affiche_gauche', array('args'=>$contexte, 'data'=>'')); |
|
| 92 | 92 | |
| 93 | - echo creer_colonne_droite("exec_$exec",true); |
|
| 93 | + echo creer_colonne_droite("exec_$exec", true); |
|
| 94 | 94 | echo $extra; |
| 95 | - echo pipeline('affiche_droite',array('args'=>$contexte,'data'=>'')); |
|
| 95 | + echo pipeline('affiche_droite', array('args'=>$contexte, 'data'=>'')); |
|
| 96 | 96 | |
| 97 | - echo debut_droite("exec_$exec",true); |
|
| 97 | + echo debut_droite("exec_$exec", true); |
|
| 98 | 98 | echo $fond; |
| 99 | - echo pipeline('affiche_milieu',array('args'=>$contexte,'data'=>'')); |
|
| 99 | + echo pipeline('affiche_milieu', array('args'=>$contexte, 'data'=>'')); |
|
| 100 | 100 | |
| 101 | - echo fin_gauche(),fin_page(); |
|
| 101 | + echo fin_gauche(), fin_page(); |
|
| 102 | 102 | } |
| 103 | 103 | } |
| 104 | 104 | |
@@ -15,7 +15,7 @@ discard block |
||
| 15 | 15 | include_spip('inc/texte'); |
| 16 | 16 | |
| 17 | 17 | // http://doc.spip.org/@exec_rechercher_dist |
| 18 | -function exec_rechercher_dist(){ |
|
| 18 | +function exec_rechercher_dist() { |
|
| 19 | 19 | $id = intval(_request('id')); |
| 20 | 20 | $exclus = intval(_request('exclus')); |
| 21 | 21 | $rac = spip_htmlentities(_request('rac')); |
@@ -28,41 +28,41 @@ discard block |
||
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | // http://doc.spip.org/@exec_rechercher_args |
| 31 | -function exec_rechercher_args($id, $type, $exclus, $rac, $do){ |
|
| 31 | +function exec_rechercher_args($id, $type, $exclus, $rac, $do) { |
|
| 32 | 32 | if (!$do) $do = 'aff'; |
| 33 | 33 | |
| 34 | 34 | $where = preg_split(",\s+,", $type); |
| 35 | - if ($where){ |
|
| 36 | - foreach ($where as $k => $v){ |
|
| 37 | - $where[$k] = "'%" . substr(str_replace("%", "\%", sql_quote($v,'','string')), 1, -1) . "%'"; |
|
| 35 | + if ($where) { |
|
| 36 | + foreach ($where as $k => $v) { |
|
| 37 | + $where[$k] = "'%".substr(str_replace("%", "\%", sql_quote($v, '', 'string')), 1, -1)."%'"; |
|
| 38 | 38 | } |
| 39 | - $where_titre = ("(titre LIKE " . join(" AND titre LIKE ", $where) . ")"); |
|
| 40 | - $where_desc = ("(descriptif LIKE " . join(" AND descriptif LIKE ", $where) . ")"); |
|
| 41 | - $where_id = ("(id_rubrique = " . intval($type) . ")"); |
|
| 39 | + $where_titre = ("(titre LIKE ".join(" AND titre LIKE ", $where).")"); |
|
| 40 | + $where_desc = ("(descriptif LIKE ".join(" AND descriptif LIKE ", $where).")"); |
|
| 41 | + $where_id = ("(id_rubrique = ".intval($type).")"); |
|
| 42 | 42 | } else { |
| 43 | 43 | $where_titre = " 1=2"; |
| 44 | 44 | $where_desc = " 1=2"; |
| 45 | 45 | $where_id = " 1=2"; |
| 46 | 46 | } |
| 47 | 47 | |
| 48 | - if ($exclus){ |
|
| 48 | + if ($exclus) { |
|
| 49 | 49 | include_spip('inc/rubriques'); |
| 50 | - $where_exclus = " AND " . sql_in('id_rubrique', calcul_branche_in($exclus), 'NOT'); |
|
| 50 | + $where_exclus = " AND ".sql_in('id_rubrique', calcul_branche_in($exclus), 'NOT'); |
|
| 51 | 51 | } else $where_exclus = ''; |
| 52 | 52 | |
| 53 | 53 | $res = sql_select("id_rubrique, id_parent, titre", "spip_rubriques", "$where_id$where_exclus"); |
| 54 | 54 | |
| 55 | 55 | $points = $rub = array(); |
| 56 | 56 | |
| 57 | - while ($row = sql_fetch($res)){ |
|
| 57 | + while ($row = sql_fetch($res)) { |
|
| 58 | 58 | $id_rubrique = $row["id_rubrique"]; |
| 59 | 59 | $rub[$id_rubrique]["titre"] = typo($row["titre"]); |
| 60 | 60 | $rub[$id_rubrique]["id_parent"] = $row["id_parent"]; |
| 61 | - $points[$id_rubrique] = $points[$id_rubrique]+3; |
|
| 61 | + $points[$id_rubrique] = $points[$id_rubrique] + 3; |
|
| 62 | 62 | } |
| 63 | 63 | $res = sql_select("id_rubrique, id_parent, titre", "spip_rubriques", "$where_titre$where_exclus"); |
| 64 | 64 | |
| 65 | - while ($row = sql_fetch($res)){ |
|
| 65 | + while ($row = sql_fetch($res)) { |
|
| 66 | 66 | $id_rubrique = $row["id_rubrique"]; |
| 67 | 67 | $rub[$id_rubrique]["titre"] = typo($row["titre"]); |
| 68 | 68 | $rub[$id_rubrique]["id_parent"] = $row["id_parent"]; |
@@ -72,7 +72,7 @@ discard block |
||
| 72 | 72 | } |
| 73 | 73 | $res = sql_select("id_rubrique, id_parent, titre", "spip_rubriques", "$where_desc$where_exclus"); |
| 74 | 74 | |
| 75 | - while ($row = sql_fetch($res)){ |
|
| 75 | + while ($row = sql_fetch($res)) { |
|
| 76 | 76 | $id_rubrique = $row["id_rubrique"]; |
| 77 | 77 | $rub[$id_rubrique]["titre"] = typo($row["titre"]); |
| 78 | 78 | $rub[$id_rubrique]["id_parent"] = $row["id_parent"]; |
@@ -81,10 +81,10 @@ discard block |
||
| 81 | 81 | else $points[$id_rubrique] = 0; |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | - if ($points){ |
|
| 84 | + if ($points) { |
|
| 85 | 85 | arsort($points); |
| 86 | - $style = " style='background-image: url(" . chemin_image('secteur-12.png') . ")'"; |
|
| 87 | - foreach ($rub as $k => $v){ |
|
| 86 | + $style = " style='background-image: url(".chemin_image('secteur-12.png').")'"; |
|
| 87 | + foreach ($rub as $k => $v) { |
|
| 88 | 88 | $rub[$k]['atts'] = ($v["id_parent"] ? $style : '') |
| 89 | 89 | . " class='petite-rubrique'"; |
| 90 | 90 | } |
@@ -99,21 +99,21 @@ discard block |
||
| 99 | 99 | // ==> attention a composer le message d'erreur avec au moins 2 balises |
| 100 | 100 | |
| 101 | 101 | // http://doc.spip.org/@proposer_item |
| 102 | -function proposer_item($ids, $titles, $rac, $type, $do){ |
|
| 102 | +function proposer_item($ids, $titles, $rac, $type, $do) { |
|
| 103 | 103 | |
| 104 | 104 | if (!$ids) |
| 105 | 105 | return "<br /><br /><div style='padding: 5px; color: red;'><b>" |
| 106 | 106 | . spip_htmlentities($type) |
| 107 | - . "</b> : " . _T('avis_aucun_resultat') . "</div>"; |
|
| 107 | + . "</b> : "._T('avis_aucun_resultat')."</div>"; |
|
| 108 | 108 | |
| 109 | 109 | $ret = ''; |
| 110 | 110 | $info = generer_url_ecrire('informer', "type=rubrique&rac=$rac&id="); |
| 111 | 111 | |
| 112 | - $onClick = "aff_selection(this.firstChild.title,'$rac" . "_selection','$info', event)"; |
|
| 112 | + $onClick = "aff_selection(this.firstChild.title,'$rac"."_selection','$info', event)"; |
|
| 113 | 113 | |
| 114 | 114 | $ondbClick = "$do(this.firstChild.firstChild.nodeValue,this.firstChild.title,'selection_rubrique', 'id_parent');"; |
| 115 | 115 | |
| 116 | - foreach ($ids as $id => $bof){ |
|
| 116 | + foreach ($ids as $id => $bof) { |
|
| 117 | 117 | |
| 118 | 118 | $titre = strtr(str_replace("'", "’", str_replace('"', """, textebrut($titles[$id]["titre"]))), "\n\r", " "); |
| 119 | 119 | |
@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | |
| 15 | 15 | |
| 16 | 16 | $fond = _request('exec'); |
| 17 | -$GLOBALS['delais'] = 0;// pas de cache ! |
|
| 17 | +$GLOBALS['delais'] = 0; // pas de cache ! |
|
| 18 | 18 | // Securite |
| 19 | 19 | if (strstr($fond, '/')) { |
| 20 | 20 | if (!include_spip('inc/autoriser') |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | // quelques inclusions et ini prealables |
| 31 | 31 | include_spip('inc/commencer_page'); |
| 32 | 32 | |
| 33 | -function shutdown_error(){ |
|
| 33 | +function shutdown_error() { |
|
| 34 | 34 | |
| 35 | 35 | // si on arrive ici avec un tampon non ferme : erreur fatale |
| 36 | 36 | /* if (ob_get_level()){ |
@@ -61,7 +61,7 @@ discard block |
||
| 61 | 61 | * La fonction ne fait rien, c'est l'inclusion du fichier qui declenche le traitement |
| 62 | 62 | * |
| 63 | 63 | */ |
| 64 | -function exec_fond_dist(){ |
|
| 64 | +function exec_fond_dist() { |
|
| 65 | 65 | |
| 66 | 66 | } |
| 67 | 67 | |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | // si jamais la liste des plugins actifs change, il faut faire un refresh du hit |
| 21 | 21 | // pour etre sur que les bons fichiers seront charges lors de l'install |
| 22 | 22 | include_spip('inc/plugin'); |
| 23 | - if (actualise_plugins_actifs()){ |
|
| 23 | + if (actualise_plugins_actifs()) { |
|
| 24 | 24 | include_spip('inc/headers'); |
| 25 | 25 | redirige_par_entete(self()); |
| 26 | 26 | } |
@@ -28,13 +28,13 @@ discard block |
||
| 28 | 28 | include_spip('inc/presentation'); |
| 29 | 29 | include_spip('inc/filtres_boites'); |
| 30 | 30 | $commencer_page = charger_fonction('commencer_page', 'inc'); |
| 31 | - echo $commencer_page('','','','',true,false,false); |
|
| 31 | + echo $commencer_page('', '', '', '', true, false, false); |
|
| 32 | 32 | |
| 33 | 33 | echo debut_grand_cadre(true); |
| 34 | - echo boite_ouvrir(_T('info_message_technique'),'notice'); |
|
| 34 | + echo boite_ouvrir(_T('info_message_technique'), 'notice'); |
|
| 35 | 35 | echo "<p>"._T('info_procedure_maj_version')."</p>", |
| 36 | 36 | "<p>"._T('info_administrateur_site_01')."</p>"; |
| 37 | - echo bouton_action(_T('bouton_mettre_a_jour_base'),generer_url_ecrire("upgrade","reinstall=non")); |
|
| 37 | + echo bouton_action(_T('bouton_mettre_a_jour_base'), generer_url_ecrire("upgrade", "reinstall=non")); |
|
| 38 | 38 | echo boite_fermer(); |
| 39 | 39 | // masquer les erreurs sql sur cette page car proviennent de la base pas a jour ! |
| 40 | 40 | echo '<style type="text/css">#debug-nav {display: none;}</style>'; |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | |
| 30 | 30 | $selectionner = charger_fonction('selectionner', 'inc'); |
| 31 | 31 | |
| 32 | - $r = $selectionner($id, "choix_parent", $exclus, $rac, $type!='breve', $do); |
|
| 32 | + $r = $selectionner($id, "choix_parent", $exclus, $rac, $type != 'breve', $do); |
|
| 33 | 33 | } else $r = ''; |
| 34 | 34 | ajax_retour($r); |
| 35 | 35 | } |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | include_spip('inc/securiser_action'); |
| 21 | 21 | |
| 22 | 22 | // http://doc.spip.org/@exec_admin_plugin_dist |
| 23 | -function exec_admin_plugin_dist($retour='') { |
|
| 23 | +function exec_admin_plugin_dist($retour = '') { |
|
| 24 | 24 | |
| 25 | 25 | if (!autoriser('configurer', '_plugins')) { |
| 26 | 26 | include_spip('inc/minipres'); |
@@ -31,9 +31,9 @@ discard block |
||
| 31 | 31 | // si jamais la liste des plugins actifs change, il faut faire un refresh du hit |
| 32 | 32 | // pour etre sur que les bons fichiers seront charges lors de l'install |
| 33 | 33 | $new = actualise_plugins_actifs(); |
| 34 | - if ($new AND _request('actualise')<2) { |
|
| 34 | + if ($new AND _request('actualise') < 2) { |
|
| 35 | 35 | include_spip('inc/headers'); |
| 36 | - redirige_par_entete(parametre_url(self(),'actualise',_request('actualise')+1,'&')); |
|
| 36 | + redirige_par_entete(parametre_url(self(), 'actualise', _request('actualise') + 1, '&')); |
|
| 37 | 37 | } |
| 38 | 38 | else { |
| 39 | 39 | admin_plug_args(_request('voir'), _request('erreur'), _request('format')); |
@@ -52,8 +52,8 @@ discard block |
||
| 52 | 52 | $commencer_page = charger_fonction('commencer_page', 'inc'); |
| 53 | 53 | echo $commencer_page(_T('icone_admin_plugin'), "configuration", "plugin"); |
| 54 | 54 | |
| 55 | - echo debut_gauche('plugin',true); |
|
| 56 | - echo recuperer_fond('prive/squelettes/navigation/configurer',array('exec'=>'admin_plugin')); |
|
| 55 | + echo debut_gauche('plugin', true); |
|
| 56 | + echo recuperer_fond('prive/squelettes/navigation/configurer', array('exec'=>'admin_plugin')); |
|
| 57 | 57 | |
| 58 | 58 | echo pipeline('affiche_gauche', |
| 59 | 59 | array( |
@@ -63,12 +63,12 @@ discard block |
||
| 63 | 63 | ); |
| 64 | 64 | |
| 65 | 65 | echo debut_droite('plugin', true); |
| 66 | - echo gros_titre(_T('icone_admin_plugin'),'',false); |
|
| 66 | + echo gros_titre(_T('icone_admin_plugin'), '', false); |
|
| 67 | 67 | |
| 68 | 68 | // Barre d'onglets de premier niveau |
| 69 | 69 | echo barre_onglets("plugins", "plugins_actifs"); |
| 70 | 70 | // Barre d'onglets de second niveau |
| 71 | - $onglet2 = $quoi=='actifs' ? 'plugins_actifs' : 'admin_plugin'; |
|
| 71 | + $onglet2 = $quoi == 'actifs' ? 'plugins_actifs' : 'admin_plugin'; |
|
| 72 | 72 | echo debut_onglet('onglets_simple second'); |
| 73 | 73 | echo onglet(_T('plugins_tous_liste'), generer_url_ecrire("admin_plugin", "voir=tous"), 'admin_plugin', $onglet2); |
| 74 | 74 | echo onglet(_T('plugins_actifs_liste'), generer_url_ecrire("admin_plugin"), 'plugins_actifs', $onglet2); |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | // message d'erreur au retour d'une operation |
| 78 | 78 | if ($erreur) |
| 79 | 79 | echo "<div class='error'>$erreur</div>"; |
| 80 | - if ($erreur_activation){ |
|
| 80 | + if ($erreur_activation) { |
|
| 81 | 81 | echo "<div class='error'>$erreur_activation</div>"; |
| 82 | 82 | } |
| 83 | 83 | |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | // Les affichages se basent sur le repertoire, pas sur le nom |
| 89 | 89 | $actifs = liste_chemin_plugin($actifs, ''); |
| 90 | 90 | if (defined('_DIR_PLUGINS_SUPPL')) |
| 91 | - $lcpas = liste_chemin_plugin($lcpa,_DIR_PLUGINS_SUPPL); |
|
| 91 | + $lcpas = liste_chemin_plugin($lcpa, _DIR_PLUGINS_SUPPL); |
|
| 92 | 92 | $lcpa = liste_chemin_plugin($lcpa); |
| 93 | 93 | |
| 94 | 94 | // on installe les plugins maintenant, |
@@ -96,15 +96,15 @@ discard block |
||
| 96 | 96 | plugin_installes_meta(); |
| 97 | 97 | |
| 98 | 98 | echo "<div class='liste-plugins formulaire_spip'>"; |
| 99 | - echo debut_cadre_trait_couleur('plugin-24.png',true,'',_T('plugins_liste'), 'plugins'); |
|
| 99 | + echo debut_cadre_trait_couleur('plugin-24.png', true, '', _T('plugins_liste'), 'plugins'); |
|
| 100 | 100 | |
| 101 | - if ($quoi!=='actifs'){ |
|
| 101 | + if ($quoi !== 'actifs') { |
|
| 102 | 102 | $lpf = liste_plugin_files(); |
| 103 | 103 | if ($lpf) |
| 104 | 104 | echo "<p>"._T('texte_presente_plugin')."</p>"; |
| 105 | 105 | else { |
| 106 | 106 | if (!@is_dir(_DIR_PLUGINS)) |
| 107 | - echo "<p>"._T('plugin_info_automatique_ftp',array('rep'=>joli_repertoire(_DIR_PLUGINS))) |
|
| 107 | + echo "<p>"._T('plugin_info_automatique_ftp', array('rep'=>joli_repertoire(_DIR_PLUGINS))) |
|
| 108 | 108 | . " — "._T('plugin_info_automatique_creer')."</p>"; |
| 109 | 109 | } |
| 110 | 110 | $lcpaffiche = $lpf; |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | $lcpaffichesup = $lcpas; |
| 120 | 120 | } |
| 121 | 121 | |
| 122 | - if ($quoi=='actifs' OR $lpf){ |
|
| 122 | + if ($quoi == 'actifs' OR $lpf) { |
|
| 123 | 123 | $nb = count($lcpa); |
| 124 | 124 | if (defined('_DIR_PLUGINS_SUPPL')) |
| 125 | 125 | $nb += count($lcpas); |
@@ -128,13 +128,13 @@ discard block |
||
| 128 | 128 | |
| 129 | 129 | if (empty($format)) |
| 130 | 130 | $format = 'liste'; |
| 131 | - elseif (!in_array($format,array('liste','repertoires'))) |
|
| 131 | + elseif (!in_array($format, array('liste', 'repertoires'))) |
|
| 132 | 132 | $format = 'repertoires'; |
| 133 | 133 | |
| 134 | - $afficher = charger_fonction("afficher_$format",'plugins'); |
|
| 135 | - $corps = $afficher(self(),$lcpaffiche, $lcpa, $actifs); |
|
| 134 | + $afficher = charger_fonction("afficher_$format", 'plugins'); |
|
| 135 | + $corps = $afficher(self(), $lcpaffiche, $lcpa, $actifs); |
|
| 136 | 136 | if (defined('_DIR_PLUGINS_SUPPL')) |
| 137 | - $corps .= $afficher(self(),$lcpaffichesup, $lcpas, $actifs, _DIR_PLUGINS_SUPPL); |
|
| 137 | + $corps .= $afficher(self(), $lcpaffichesup, $lcpas, $actifs, _DIR_PLUGINS_SUPPL); |
|
| 138 | 138 | |
| 139 | 139 | if ($corps) |
| 140 | 140 | $corps .= "\n<div class='boutons' style='display:none;'>" |
@@ -142,11 +142,11 @@ discard block |
||
| 142 | 142 | ."' />" |
| 143 | 143 | . "</div>"; |
| 144 | 144 | |
| 145 | - echo redirige_action_post('activer_plugins','activer','admin_plugin','', $corps); |
|
| 145 | + echo redirige_action_post('activer_plugins', 'activer', 'admin_plugin', '', $corps); |
|
| 146 | 146 | |
| 147 | 147 | echo fin_cadre_trait_couleur(true); |
| 148 | 148 | |
| 149 | - if ($quoi=='actifs') |
|
| 149 | + if ($quoi == 'actifs') |
|
| 150 | 150 | echo affiche_les_plugins_verrouilles($actifs); |
| 151 | 151 | echo "</div>"; |
| 152 | 152 | |
@@ -190,15 +190,15 @@ discard block |
||
| 190 | 190 | { |
| 191 | 191 | if ((!$liste = liste_plugin_files(_DIR_PLUGINS_DIST))) return ''; |
| 192 | 192 | |
| 193 | - $afficher = charger_fonction("afficher_liste",'plugins'); |
|
| 193 | + $afficher = charger_fonction("afficher_liste", 'plugins'); |
|
| 194 | 194 | $liste = $afficher(self(), $liste, array(), $actifs, _DIR_PLUGINS_DIST); |
| 195 | 195 | |
| 196 | 196 | return |
| 197 | 197 | "<div id='plugins_dist'>" |
| 198 | - . debut_cadre_trait_couleur('',true,'',_T('plugins_liste_dist'), 'liste_plugins_dist') |
|
| 198 | + . debut_cadre_trait_couleur('', true, '', _T('plugins_liste_dist'), 'liste_plugins_dist') |
|
| 199 | 199 | . "<p>" |
| 200 | 200 | . _T('plugin_info_plugins_dist_1', array('plugins_dist' => joli_repertoire(_DIR_PLUGINS_DIST))) |
| 201 | - . '<br />'. _T('plugin_info_plugins_dist_2') |
|
| 201 | + . '<br />'._T('plugin_info_plugins_dist_2') |
|
| 202 | 202 | . "</p>" |
| 203 | 203 | . $liste |
| 204 | 204 | . fin_cadre_trait_couleur(true) |
@@ -210,7 +210,7 @@ discard block |
||
| 210 | 210 | * |
| 211 | 211 | * @return <type> |
| 212 | 212 | */ |
| 213 | -function afficher_librairies(){ |
|
| 213 | +function afficher_librairies() { |
|
| 214 | 214 | |
| 215 | 215 | if (!$libs = liste_librairies()) return ''; |
| 216 | 216 | ksort($libs); |
@@ -16,22 +16,22 @@ discard block |
||
| 16 | 16 | |
| 17 | 17 | // http://doc.spip.org/@debutElement |
| 18 | 18 | function debutElement($phraseur, $name, $attrs) |
| 19 | -{ xml_debutElement($this, $name, $attrs);} |
|
| 19 | +{ xml_debutElement($this, $name, $attrs); } |
|
| 20 | 20 | |
| 21 | 21 | // http://doc.spip.org/@finElement |
| 22 | 22 | function finElement($phraseur, $name) |
| 23 | -{ xml_finElement($this, $name);} |
|
| 23 | +{ xml_finElement($this, $name); } |
|
| 24 | 24 | |
| 25 | 25 | // http://doc.spip.org/@textElement |
| 26 | 26 | function textElement($phraseur, $data) |
| 27 | -{ xml_textElement($this, $data);} |
|
| 27 | +{ xml_textElement($this, $data); } |
|
| 28 | 28 | |
| 29 | 29 | function piElement($phraseur, $target, $data) |
| 30 | -{ xml_PiElement($this, $target, $data);} |
|
| 30 | +{ xml_PiElement($this, $target, $data); } |
|
| 31 | 31 | |
| 32 | 32 | // http://doc.spip.org/@defautElement |
| 33 | 33 | function defaultElement($phraseur, $data) |
| 34 | -{ xml_defaultElement($this, $data);} |
|
| 34 | +{ xml_defaultElement($this, $data); } |
|
| 35 | 35 | |
| 36 | 36 | // http://doc.spip.org/@phraserTout |
| 37 | 37 | function phraserTout($phraseur, $data) |
@@ -52,14 +52,14 @@ discard block |
||
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | // http://doc.spip.org/@xml_indenter_dist |
| 55 | -function xml_indenter_dist($page, $apply=false) |
|
| 55 | +function xml_indenter_dist($page, $apply = false) |
|
| 56 | 56 | { |
| 57 | 57 | $sax = charger_fonction('sax', 'xml'); |
| 58 | 58 | $f = new IndenteurXML(); |
| 59 | 59 | $sax($page, $apply, $f); |
| 60 | - if (!$f->err) return $f->entete . $f->res; |
|
| 61 | - spip_log("indentation impossible " . count($f->err) . " erreurs de validation"); |
|
| 62 | - return $f->entete . $f->page; |
|
| 60 | + if (!$f->err) return $f->entete.$f->res; |
|
| 61 | + spip_log("indentation impossible ".count($f->err)." erreurs de validation"); |
|
| 62 | + return $f->entete.$f->page; |
|
| 63 | 63 | } |
| 64 | 64 | |
| 65 | 65 | ?> |