@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | */ |
| 18 | 18 | |
| 19 | 19 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 20 | - return; |
|
| 20 | + return; |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | include_spip('inc/actions'); |
@@ -29,22 +29,22 @@ discard block |
||
| 29 | 29 | * @return void |
| 30 | 30 | */ |
| 31 | 31 | function action_etre_webmestre_dist() { |
| 32 | - $securiser_action = charger_fonction('securiser_action', 'inc'); |
|
| 33 | - $time = $securiser_action(); |
|
| 34 | - |
|
| 35 | - if (time() - $time < 15 * 60 |
|
| 36 | - and $GLOBALS['visiteur_session']['statut'] == '0minirezo' |
|
| 37 | - and $GLOBALS['visiteur_session']['webmestre'] !== 'oui' |
|
| 38 | - ) { |
|
| 39 | - $action = _T('info_admin_etre_webmestre'); |
|
| 40 | - $admin = charger_fonction('admin', 'inc'); |
|
| 41 | - // lance la verif par ftp et l'appel |
|
| 42 | - // a base_etre_webmestre_dist quand c'est OK |
|
| 43 | - if ($r = $admin('etre_webmestre', $action)) { |
|
| 44 | - echo $r; |
|
| 45 | - exit; |
|
| 46 | - } |
|
| 47 | - } |
|
| 32 | + $securiser_action = charger_fonction('securiser_action', 'inc'); |
|
| 33 | + $time = $securiser_action(); |
|
| 34 | + |
|
| 35 | + if (time() - $time < 15 * 60 |
|
| 36 | + and $GLOBALS['visiteur_session']['statut'] == '0minirezo' |
|
| 37 | + and $GLOBALS['visiteur_session']['webmestre'] !== 'oui' |
|
| 38 | + ) { |
|
| 39 | + $action = _T('info_admin_etre_webmestre'); |
|
| 40 | + $admin = charger_fonction('admin', 'inc'); |
|
| 41 | + // lance la verif par ftp et l'appel |
|
| 42 | + // a base_etre_webmestre_dist quand c'est OK |
|
| 43 | + if ($r = $admin('etre_webmestre', $action)) { |
|
| 44 | + echo $r; |
|
| 45 | + exit; |
|
| 46 | + } |
|
| 47 | + } |
|
| 48 | 48 | |
| 49 | 49 | } |
| 50 | 50 | |
@@ -54,8 +54,8 @@ discard block |
||
| 54 | 54 | * @return void |
| 55 | 55 | */ |
| 56 | 56 | function base_etre_webmestre_dist() { |
| 57 | - if ($GLOBALS['visiteur_session']['statut'] == '0minirezo' and $GLOBALS['visiteur_session']['webmestre'] !== 'oui') { |
|
| 58 | - include_spip('action/editer_auteur'); |
|
| 59 | - auteur_instituer($GLOBALS['visiteur_session']['id_auteur'], array('webmestre' => 'oui'), true); |
|
| 60 | - } |
|
| 57 | + if ($GLOBALS['visiteur_session']['statut'] == '0minirezo' and $GLOBALS['visiteur_session']['webmestre'] !== 'oui') { |
|
| 58 | + include_spip('action/editer_auteur'); |
|
| 59 | + auteur_instituer($GLOBALS['visiteur_session']['id_auteur'], array('webmestre' => 'oui'), true); |
|
| 60 | + } |
|
| 61 | 61 | } |
@@ -11,126 +11,126 @@ |
||
| 11 | 11 | \***************************************************************************/ |
| 12 | 12 | |
| 13 | 13 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 14 | - return; |
|
| 14 | + return; |
|
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | function format_boucle_html($preaff, $avant, $nom, $type, $crit, $corps, $apres, $altern, $postaff, $prof) { |
| 18 | - $preaff = $preaff ? "<BB$nom>$preaff" : ""; |
|
| 19 | - $avant = $avant ? "<B$nom>$avant" : ""; |
|
| 20 | - $apres = $apres ? "$apres</B$nom>" : ""; |
|
| 21 | - $altern = $altern ? "$altern<//B$nom>" : ""; |
|
| 22 | - $postaff = $postaff ? "$postaff</BB$nom>" : ""; |
|
| 23 | - if (!$corps) { |
|
| 24 | - $corps = " />"; |
|
| 25 | - } else { |
|
| 26 | - $corps = ">$corps</BOUCLE$nom>"; |
|
| 27 | - } |
|
| 28 | - |
|
| 29 | - return "$preaff$avant<BOUCLE$nom($type)$crit$corps$apres$altern$postaff"; |
|
| 18 | + $preaff = $preaff ? "<BB$nom>$preaff" : ""; |
|
| 19 | + $avant = $avant ? "<B$nom>$avant" : ""; |
|
| 20 | + $apres = $apres ? "$apres</B$nom>" : ""; |
|
| 21 | + $altern = $altern ? "$altern<//B$nom>" : ""; |
|
| 22 | + $postaff = $postaff ? "$postaff</BB$nom>" : ""; |
|
| 23 | + if (!$corps) { |
|
| 24 | + $corps = " />"; |
|
| 25 | + } else { |
|
| 26 | + $corps = ">$corps</BOUCLE$nom>"; |
|
| 27 | + } |
|
| 28 | + |
|
| 29 | + return "$preaff$avant<BOUCLE$nom($type)$crit$corps$apres$altern$postaff"; |
|
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | function format_inclure_html($file, $args, $prof) { |
| 33 | - if (strpos($file, '#') === false) { |
|
| 34 | - $t = $file ? ("(" . $file . ")") : ""; |
|
| 35 | - } else { |
|
| 36 | - $t = "{fond=" . $file . '}'; |
|
| 37 | - } |
|
| 38 | - $args = !$args ? '' : ("{" . join(", ", $args) . "}"); |
|
| 39 | - |
|
| 40 | - return ("<INCLURE" . $t . $args . ">"); |
|
| 33 | + if (strpos($file, '#') === false) { |
|
| 34 | + $t = $file ? ("(" . $file . ")") : ""; |
|
| 35 | + } else { |
|
| 36 | + $t = "{fond=" . $file . '}'; |
|
| 37 | + } |
|
| 38 | + $args = !$args ? '' : ("{" . join(", ", $args) . "}"); |
|
| 39 | + |
|
| 40 | + return ("<INCLURE" . $t . $args . ">"); |
|
| 41 | 41 | } |
| 42 | 42 | |
| 43 | 43 | function format_polyglotte_html($args, $prof) { |
| 44 | - $contenu = array(); |
|
| 45 | - foreach ($args as $l => $t) { |
|
| 46 | - $contenu[] = ($l ? "[$l]" : '') . $t; |
|
| 47 | - } |
|
| 44 | + $contenu = array(); |
|
| 45 | + foreach ($args as $l => $t) { |
|
| 46 | + $contenu[] = ($l ? "[$l]" : '') . $t; |
|
| 47 | + } |
|
| 48 | 48 | |
| 49 | - return ("<multi>" . join(" ", $contenu) . "</multi>"); |
|
| 49 | + return ("<multi>" . join(" ", $contenu) . "</multi>"); |
|
| 50 | 50 | } |
| 51 | 51 | |
| 52 | 52 | function format_idiome_html($nom, $module, $args, $filtres, $prof) { |
| 53 | - foreach ($args as $k => $v) { |
|
| 54 | - $args[$k] = "$k=$v"; |
|
| 55 | - } |
|
| 56 | - $args = (!$args ? '' : ('{' . join(',', $args) . '}')); |
|
| 53 | + foreach ($args as $k => $v) { |
|
| 54 | + $args[$k] = "$k=$v"; |
|
| 55 | + } |
|
| 56 | + $args = (!$args ? '' : ('{' . join(',', $args) . '}')); |
|
| 57 | 57 | |
| 58 | - return ("<:" . ($module ? "$module:" : "") . $nom . $args . $filtres . ":>"); |
|
| 58 | + return ("<:" . ($module ? "$module:" : "") . $nom . $args . $filtres . ":>"); |
|
| 59 | 59 | } |
| 60 | 60 | |
| 61 | 61 | function format_champ_html($nom, $boucle, $etoile, $avant, $apres, $args, $filtres, $prof) { |
| 62 | - $nom = "#" |
|
| 63 | - . ($boucle ? ($boucle . ":") : "") |
|
| 64 | - . $nom |
|
| 65 | - . $etoile |
|
| 66 | - . $args |
|
| 67 | - . $filtres; |
|
| 62 | + $nom = "#" |
|
| 63 | + . ($boucle ? ($boucle . ":") : "") |
|
| 64 | + . $nom |
|
| 65 | + . $etoile |
|
| 66 | + . $args |
|
| 67 | + . $filtres; |
|
| 68 | 68 | |
| 69 | - // Determiner si c'est un champ etendu, |
|
| 69 | + // Determiner si c'est un champ etendu, |
|
| 70 | 70 | |
| 71 | - $s = ($avant or $apres or $filtres |
|
| 72 | - or (strpos($args, '(#') !== false)); |
|
| 71 | + $s = ($avant or $apres or $filtres |
|
| 72 | + or (strpos($args, '(#') !== false)); |
|
| 73 | 73 | |
| 74 | - return ($s ? "[$avant($nom)$apres]" : $nom); |
|
| 74 | + return ($s ? "[$avant($nom)$apres]" : $nom); |
|
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | function format_critere_html($critere) { |
| 78 | - foreach ($critere as $k => $crit) { |
|
| 79 | - $crit_s = ''; |
|
| 80 | - foreach ($crit as $operande) { |
|
| 81 | - list($type, $valeur) = $operande; |
|
| 82 | - if ($type == 'champ' and $valeur[0] == '[') { |
|
| 83 | - $valeur = substr($valeur, 1, -1); |
|
| 84 | - if (preg_match(',^[(](#[^|]*)[)]$,sS', $valeur)) { |
|
| 85 | - $valeur = substr($valeur, 1, -1); |
|
| 86 | - } |
|
| 87 | - } |
|
| 88 | - $crit_s .= $valeur; |
|
| 89 | - } |
|
| 90 | - $critere[$k] = $crit_s; |
|
| 91 | - } |
|
| 92 | - |
|
| 93 | - return (!$critere ? "" : ("{" . join(",", $critere) . "}")); |
|
| 78 | + foreach ($critere as $k => $crit) { |
|
| 79 | + $crit_s = ''; |
|
| 80 | + foreach ($crit as $operande) { |
|
| 81 | + list($type, $valeur) = $operande; |
|
| 82 | + if ($type == 'champ' and $valeur[0] == '[') { |
|
| 83 | + $valeur = substr($valeur, 1, -1); |
|
| 84 | + if (preg_match(',^[(](#[^|]*)[)]$,sS', $valeur)) { |
|
| 85 | + $valeur = substr($valeur, 1, -1); |
|
| 86 | + } |
|
| 87 | + } |
|
| 88 | + $crit_s .= $valeur; |
|
| 89 | + } |
|
| 90 | + $critere[$k] = $crit_s; |
|
| 91 | + } |
|
| 92 | + |
|
| 93 | + return (!$critere ? "" : ("{" . join(",", $critere) . "}")); |
|
| 94 | 94 | } |
| 95 | 95 | |
| 96 | 96 | function format_liste_html($fonc, $args, $prof) { |
| 97 | - return ((($fonc !== '') ? "|$fonc" : $fonc) |
|
| 98 | - . (!$args ? "" : ("{" . join(",", $args) . "}"))); |
|
| 97 | + return ((($fonc !== '') ? "|$fonc" : $fonc) |
|
| 98 | + . (!$args ? "" : ("{" . join(",", $args) . "}"))); |
|
| 99 | 99 | } |
| 100 | 100 | |
| 101 | 101 | // Concatenation sans separateur: verifier qu'on ne cree pas de faux lexemes |
| 102 | 102 | function format_suite_html($args) { |
| 103 | - for ($i = 0; $i < count($args) - 1; $i++) { |
|
| 104 | - list($texte, $type) = $args[$i]; |
|
| 105 | - list($texte2, $type2) = $args[$i + 1]; |
|
| 106 | - if (!$texte or !$texte2) { |
|
| 107 | - continue; |
|
| 108 | - } |
|
| 109 | - $c1 = substr($texte, -1); |
|
| 110 | - if ($type2 !== 'texte') { |
|
| 111 | - // si un texte se termine par ( et est suivi d'un champ |
|
| 112 | - // ou assimiles, forcer la notation pleine |
|
| 113 | - if ($c1 == '(' and substr($texte2, 0, 1) == '#') { |
|
| 114 | - $args[$i + 1][0] = '[(' . $texte2 . ')]'; |
|
| 115 | - } |
|
| 116 | - } else { |
|
| 117 | - if ($type == 'texte') { |
|
| 118 | - continue; |
|
| 119 | - } |
|
| 120 | - // si un champ ou assimiles est suivi d'un texte |
|
| 121 | - // et si celui-ci commence par un caractere de champ |
|
| 122 | - // forcer la notation pleine |
|
| 123 | - if (($c1 == '}' and substr(ltrim($texte2), 0, 1) == '|') |
|
| 124 | - or (preg_match('/[\w\d_*]/', $c1) and preg_match('/^[\w\d_*{|]/', $texte2)) |
|
| 125 | - ) { |
|
| 126 | - $args[$i][0] = '[(' . $texte . ')]'; |
|
| 127 | - } |
|
| 128 | - } |
|
| 129 | - } |
|
| 130 | - |
|
| 131 | - return join("", array_map(function($arg) { return reset($arg); }, $args)); |
|
| 103 | + for ($i = 0; $i < count($args) - 1; $i++) { |
|
| 104 | + list($texte, $type) = $args[$i]; |
|
| 105 | + list($texte2, $type2) = $args[$i + 1]; |
|
| 106 | + if (!$texte or !$texte2) { |
|
| 107 | + continue; |
|
| 108 | + } |
|
| 109 | + $c1 = substr($texte, -1); |
|
| 110 | + if ($type2 !== 'texte') { |
|
| 111 | + // si un texte se termine par ( et est suivi d'un champ |
|
| 112 | + // ou assimiles, forcer la notation pleine |
|
| 113 | + if ($c1 == '(' and substr($texte2, 0, 1) == '#') { |
|
| 114 | + $args[$i + 1][0] = '[(' . $texte2 . ')]'; |
|
| 115 | + } |
|
| 116 | + } else { |
|
| 117 | + if ($type == 'texte') { |
|
| 118 | + continue; |
|
| 119 | + } |
|
| 120 | + // si un champ ou assimiles est suivi d'un texte |
|
| 121 | + // et si celui-ci commence par un caractere de champ |
|
| 122 | + // forcer la notation pleine |
|
| 123 | + if (($c1 == '}' and substr(ltrim($texte2), 0, 1) == '|') |
|
| 124 | + or (preg_match('/[\w\d_*]/', $c1) and preg_match('/^[\w\d_*{|]/', $texte2)) |
|
| 125 | + ) { |
|
| 126 | + $args[$i][0] = '[(' . $texte . ')]'; |
|
| 127 | + } |
|
| 128 | + } |
|
| 129 | + } |
|
| 130 | + |
|
| 131 | + return join("", array_map(function($arg) { return reset($arg); }, $args)); |
|
| 132 | 132 | } |
| 133 | 133 | |
| 134 | 134 | function format_texte_html($texte) { |
| 135 | - return $texte; |
|
| 135 | + return $texte; |
|
| 136 | 136 | } |
@@ -18,7 +18,7 @@ discard block |
||
| 18 | 18 | **/ |
| 19 | 19 | |
| 20 | 20 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 21 | - return; |
|
| 21 | + return; |
|
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | /** |
@@ -28,22 +28,22 @@ discard block |
||
| 28 | 28 | * Environnement du formulaire |
| 29 | 29 | **/ |
| 30 | 30 | function formulaires_configurer_reducteur_charger_dist() { |
| 31 | - $valeurs = array(); |
|
| 32 | - foreach (array( |
|
| 33 | - 'image_process', |
|
| 34 | - 'formats_graphiques', |
|
| 35 | - 'creer_preview', |
|
| 36 | - 'taille_preview', |
|
| 37 | - ) as $m) { |
|
| 38 | - $valeurs[$m] = isset($GLOBALS['meta'][$m]) ? $GLOBALS['meta'][$m] : null; |
|
| 39 | - } |
|
| 31 | + $valeurs = array(); |
|
| 32 | + foreach (array( |
|
| 33 | + 'image_process', |
|
| 34 | + 'formats_graphiques', |
|
| 35 | + 'creer_preview', |
|
| 36 | + 'taille_preview', |
|
| 37 | + ) as $m) { |
|
| 38 | + $valeurs[$m] = isset($GLOBALS['meta'][$m]) ? $GLOBALS['meta'][$m] : null; |
|
| 39 | + } |
|
| 40 | 40 | |
| 41 | - $valeurs['taille_preview'] = intval($valeurs['taille_preview']); |
|
| 42 | - if ($valeurs['taille_preview'] < 10) { |
|
| 43 | - $valeurs['taille_preview'] = 120; |
|
| 44 | - } |
|
| 41 | + $valeurs['taille_preview'] = intval($valeurs['taille_preview']); |
|
| 42 | + if ($valeurs['taille_preview'] < 10) { |
|
| 43 | + $valeurs['taille_preview'] = 120; |
|
| 44 | + } |
|
| 45 | 45 | |
| 46 | - return $valeurs; |
|
| 46 | + return $valeurs; |
|
| 47 | 47 | } |
| 48 | 48 | |
| 49 | 49 | |
@@ -54,51 +54,51 @@ discard block |
||
| 54 | 54 | * Retours des traitements |
| 55 | 55 | **/ |
| 56 | 56 | function formulaires_configurer_reducteur_traiter_dist() { |
| 57 | - $res = array('editable' => true); |
|
| 57 | + $res = array('editable' => true); |
|
| 58 | 58 | |
| 59 | - if (is_array($image_process = _request('image_process_'))) { |
|
| 60 | - $image_process = array_keys($image_process); |
|
| 61 | - $image_process = reset($image_process); |
|
| 59 | + if (is_array($image_process = _request('image_process_'))) { |
|
| 60 | + $image_process = array_keys($image_process); |
|
| 61 | + $image_process = reset($image_process); |
|
| 62 | 62 | |
| 63 | - // application du choix de vignette |
|
| 64 | - if ($image_process) { |
|
| 65 | - // mettre a jour les formats graphiques lisibles |
|
| 66 | - switch ($image_process) { |
|
| 67 | - case 'gd1': |
|
| 68 | - case 'gd2': |
|
| 69 | - $formats_graphiques = $GLOBALS['meta']['gd_formats_read']; |
|
| 70 | - break; |
|
| 71 | - case 'netpbm': |
|
| 72 | - $formats_graphiques = $GLOBALS['meta']['netpbm_formats']; |
|
| 73 | - break; |
|
| 74 | - case 'convert': |
|
| 75 | - case 'imagick': |
|
| 76 | - $formats_graphiques = 'gif,jpg,png,webp'; |
|
| 77 | - break; |
|
| 78 | - default: #debug |
|
| 79 | - $formats_graphiques = ''; |
|
| 80 | - $image_process = 'non'; |
|
| 81 | - break; |
|
| 82 | - } |
|
| 83 | - ecrire_meta('formats_graphiques', $formats_graphiques, 'non'); |
|
| 84 | - ecrire_meta('image_process', $image_process, 'non'); |
|
| 85 | - } |
|
| 86 | - } |
|
| 63 | + // application du choix de vignette |
|
| 64 | + if ($image_process) { |
|
| 65 | + // mettre a jour les formats graphiques lisibles |
|
| 66 | + switch ($image_process) { |
|
| 67 | + case 'gd1': |
|
| 68 | + case 'gd2': |
|
| 69 | + $formats_graphiques = $GLOBALS['meta']['gd_formats_read']; |
|
| 70 | + break; |
|
| 71 | + case 'netpbm': |
|
| 72 | + $formats_graphiques = $GLOBALS['meta']['netpbm_formats']; |
|
| 73 | + break; |
|
| 74 | + case 'convert': |
|
| 75 | + case 'imagick': |
|
| 76 | + $formats_graphiques = 'gif,jpg,png,webp'; |
|
| 77 | + break; |
|
| 78 | + default: #debug |
|
| 79 | + $formats_graphiques = ''; |
|
| 80 | + $image_process = 'non'; |
|
| 81 | + break; |
|
| 82 | + } |
|
| 83 | + ecrire_meta('formats_graphiques', $formats_graphiques, 'non'); |
|
| 84 | + ecrire_meta('image_process', $image_process, 'non'); |
|
| 85 | + } |
|
| 86 | + } |
|
| 87 | 87 | |
| 88 | - foreach (array( |
|
| 89 | - 'creer_preview' |
|
| 90 | - ) as $m) { |
|
| 91 | - if (!is_null($v = _request($m))) { |
|
| 92 | - ecrire_meta($m, $v == 'oui' ? 'oui' : 'non'); |
|
| 93 | - } |
|
| 94 | - } |
|
| 95 | - if (!is_null($v = _request('taille_preview'))) { |
|
| 96 | - ecrire_meta('taille_preview', intval($v)); |
|
| 97 | - } |
|
| 88 | + foreach (array( |
|
| 89 | + 'creer_preview' |
|
| 90 | + ) as $m) { |
|
| 91 | + if (!is_null($v = _request($m))) { |
|
| 92 | + ecrire_meta($m, $v == 'oui' ? 'oui' : 'non'); |
|
| 93 | + } |
|
| 94 | + } |
|
| 95 | + if (!is_null($v = _request('taille_preview'))) { |
|
| 96 | + ecrire_meta('taille_preview', intval($v)); |
|
| 97 | + } |
|
| 98 | 98 | |
| 99 | - $res['message_ok'] = _T('config_info_enregistree'); |
|
| 99 | + $res['message_ok'] = _T('config_info_enregistree'); |
|
| 100 | 100 | |
| 101 | - return $res; |
|
| 101 | + return $res; |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | /** |
@@ -111,36 +111,36 @@ discard block |
||
| 111 | 111 | * URL d'action pour tester la librairie graphique en créant une vignette |
| 112 | 112 | **/ |
| 113 | 113 | function url_vignette_choix($process) { |
| 114 | - switch ($process) { |
|
| 115 | - case 'gd2': |
|
| 116 | - if (!function_exists('ImageCreateTrueColor')) { |
|
| 117 | - return ''; |
|
| 118 | - } |
|
| 119 | - break; |
|
| 120 | - case 'gd1': |
|
| 121 | - if (!function_exists('ImageGif') |
|
| 122 | - and !function_exists('ImageJpeg') |
|
| 123 | - and !function_exists('ImagePng') |
|
| 124 | - ) { |
|
| 125 | - return ''; |
|
| 126 | - } |
|
| 127 | - break; |
|
| 128 | - case 'netpbm': |
|
| 129 | - if (defined('_PNMSCALE_COMMAND') and _PNMSCALE_COMMAND == '') { |
|
| 130 | - return ''; |
|
| 131 | - } |
|
| 132 | - break; |
|
| 133 | - case 'imagick': |
|
| 134 | - if (!method_exists('Imagick', 'readImage')) { |
|
| 135 | - return ''; |
|
| 136 | - } |
|
| 137 | - break; |
|
| 138 | - case 'convert': |
|
| 139 | - if (defined('_CONVERT_COMMAND') and _CONVERT_COMMAND == '') { |
|
| 140 | - return ''; |
|
| 141 | - } |
|
| 142 | - break; |
|
| 143 | - } |
|
| 114 | + switch ($process) { |
|
| 115 | + case 'gd2': |
|
| 116 | + if (!function_exists('ImageCreateTrueColor')) { |
|
| 117 | + return ''; |
|
| 118 | + } |
|
| 119 | + break; |
|
| 120 | + case 'gd1': |
|
| 121 | + if (!function_exists('ImageGif') |
|
| 122 | + and !function_exists('ImageJpeg') |
|
| 123 | + and !function_exists('ImagePng') |
|
| 124 | + ) { |
|
| 125 | + return ''; |
|
| 126 | + } |
|
| 127 | + break; |
|
| 128 | + case 'netpbm': |
|
| 129 | + if (defined('_PNMSCALE_COMMAND') and _PNMSCALE_COMMAND == '') { |
|
| 130 | + return ''; |
|
| 131 | + } |
|
| 132 | + break; |
|
| 133 | + case 'imagick': |
|
| 134 | + if (!method_exists('Imagick', 'readImage')) { |
|
| 135 | + return ''; |
|
| 136 | + } |
|
| 137 | + break; |
|
| 138 | + case 'convert': |
|
| 139 | + if (defined('_CONVERT_COMMAND') and _CONVERT_COMMAND == '') { |
|
| 140 | + return ''; |
|
| 141 | + } |
|
| 142 | + break; |
|
| 143 | + } |
|
| 144 | 144 | |
| 145 | - return generer_url_action('tester', "arg=$process&time=" . time()); |
|
| 145 | + return generer_url_action('tester', "arg=$process&time=" . time()); |
|
| 146 | 146 | } |
@@ -17,12 +17,12 @@ discard block |
||
| 17 | 17 | **/ |
| 18 | 18 | |
| 19 | 19 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 20 | - return; |
|
| 20 | + return; |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | if (!defined('_TEST_FILE_EXISTS')) { |
| 24 | - /** Permettre d'éviter des tests file_exists sur certains hébergeurs */ |
|
| 25 | - define('_TEST_FILE_EXISTS', preg_match(',(online|free)[.]fr$,', isset($_ENV["HTTP_HOST"]) ? $_ENV["HTTP_HOST"] : "")); |
|
| 24 | + /** Permettre d'éviter des tests file_exists sur certains hébergeurs */ |
|
| 25 | + define('_TEST_FILE_EXISTS', preg_match(',(online|free)[.]fr$,', isset($_ENV["HTTP_HOST"]) ? $_ENV["HTTP_HOST"] : "")); |
|
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | #define('_SPIP_LOCK_MODE',0); // ne pas utiliser de lock (deconseille) |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | #define('_SPIP_LOCK_MODE',2); // utiliser le nfslock de spip |
| 31 | 31 | |
| 32 | 32 | if (_SPIP_LOCK_MODE == 2) { |
| 33 | - include_spip('inc/nfslock'); |
|
| 33 | + include_spip('inc/nfslock'); |
|
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | $GLOBALS['liste_verrous'] = array(); |
@@ -53,24 +53,24 @@ discard block |
||
| 53 | 53 | * Ressource sur le fichier ouvert, sinon false. |
| 54 | 54 | **/ |
| 55 | 55 | function spip_fopen_lock($fichier, $mode, $verrou) { |
| 56 | - if (_SPIP_LOCK_MODE == 1) { |
|
| 57 | - if ($fl = @fopen($fichier, $mode)) { |
|
| 58 | - // verrou |
|
| 59 | - @flock($fl, $verrou); |
|
| 60 | - } |
|
| 61 | - |
|
| 62 | - return $fl; |
|
| 63 | - } elseif (_SPIP_LOCK_MODE == 2) { |
|
| 64 | - if (($verrou = spip_nfslock($fichier)) && ($fl = @fopen($fichier, $mode))) { |
|
| 65 | - $GLOBALS['liste_verrous'][$fl] = array($fichier, $verrou); |
|
| 66 | - |
|
| 67 | - return $fl; |
|
| 68 | - } else { |
|
| 69 | - return false; |
|
| 70 | - } |
|
| 71 | - } |
|
| 72 | - |
|
| 73 | - return @fopen($fichier, $mode); |
|
| 56 | + if (_SPIP_LOCK_MODE == 1) { |
|
| 57 | + if ($fl = @fopen($fichier, $mode)) { |
|
| 58 | + // verrou |
|
| 59 | + @flock($fl, $verrou); |
|
| 60 | + } |
|
| 61 | + |
|
| 62 | + return $fl; |
|
| 63 | + } elseif (_SPIP_LOCK_MODE == 2) { |
|
| 64 | + if (($verrou = spip_nfslock($fichier)) && ($fl = @fopen($fichier, $mode))) { |
|
| 65 | + $GLOBALS['liste_verrous'][$fl] = array($fichier, $verrou); |
|
| 66 | + |
|
| 67 | + return $fl; |
|
| 68 | + } else { |
|
| 69 | + return false; |
|
| 70 | + } |
|
| 71 | + } |
|
| 72 | + |
|
| 73 | + return @fopen($fichier, $mode); |
|
| 74 | 74 | } |
| 75 | 75 | |
| 76 | 76 | /** |
@@ -85,14 +85,14 @@ discard block |
||
| 85 | 85 | * true si succès, false sinon. |
| 86 | 86 | **/ |
| 87 | 87 | function spip_fclose_unlock($handle) { |
| 88 | - if (_SPIP_LOCK_MODE == 1) { |
|
| 89 | - @flock($handle, LOCK_UN); |
|
| 90 | - } elseif (_SPIP_LOCK_MODE == 2) { |
|
| 91 | - spip_nfsunlock(reset($GLOBALS['liste_verrous'][$handle]), end($GLOBALS['liste_verrous'][$handle])); |
|
| 92 | - unset($GLOBALS['liste_verrous'][$handle]); |
|
| 93 | - } |
|
| 94 | - |
|
| 95 | - return @fclose($handle); |
|
| 88 | + if (_SPIP_LOCK_MODE == 1) { |
|
| 89 | + @flock($handle, LOCK_UN); |
|
| 90 | + } elseif (_SPIP_LOCK_MODE == 2) { |
|
| 91 | + spip_nfsunlock(reset($GLOBALS['liste_verrous'][$handle]), end($GLOBALS['liste_verrous'][$handle])); |
|
| 92 | + unset($GLOBALS['liste_verrous'][$handle]); |
|
| 93 | + } |
|
| 94 | + |
|
| 95 | + return @fclose($handle); |
|
| 96 | 96 | } |
| 97 | 97 | |
| 98 | 98 | |
@@ -106,23 +106,23 @@ discard block |
||
| 106 | 106 | * Contenu du fichier |
| 107 | 107 | **/ |
| 108 | 108 | function spip_file_get_contents($fichier) { |
| 109 | - if (substr($fichier, -3) != '.gz') { |
|
| 110 | - if (function_exists('file_get_contents')) { |
|
| 111 | - // quand on est sous windows on ne sait pas si file_get_contents marche |
|
| 112 | - // on essaye : si ca retourne du contenu alors c'est bon |
|
| 113 | - // sinon on fait un file() pour avoir le coeur net |
|
| 114 | - $contenu = @file_get_contents($fichier); |
|
| 115 | - if (!$contenu and _OS_SERVEUR == 'windows') { |
|
| 116 | - $contenu = @file($fichier); |
|
| 117 | - } |
|
| 118 | - } else { |
|
| 119 | - $contenu = @file($fichier); |
|
| 120 | - } |
|
| 121 | - } else { |
|
| 122 | - $contenu = @gzfile($fichier); |
|
| 123 | - } |
|
| 124 | - |
|
| 125 | - return is_array($contenu) ? join('', $contenu) : (string)$contenu; |
|
| 109 | + if (substr($fichier, -3) != '.gz') { |
|
| 110 | + if (function_exists('file_get_contents')) { |
|
| 111 | + // quand on est sous windows on ne sait pas si file_get_contents marche |
|
| 112 | + // on essaye : si ca retourne du contenu alors c'est bon |
|
| 113 | + // sinon on fait un file() pour avoir le coeur net |
|
| 114 | + $contenu = @file_get_contents($fichier); |
|
| 115 | + if (!$contenu and _OS_SERVEUR == 'windows') { |
|
| 116 | + $contenu = @file($fichier); |
|
| 117 | + } |
|
| 118 | + } else { |
|
| 119 | + $contenu = @file($fichier); |
|
| 120 | + } |
|
| 121 | + } else { |
|
| 122 | + $contenu = @gzfile($fichier); |
|
| 123 | + } |
|
| 124 | + |
|
| 125 | + return is_array($contenu) ? join('', $contenu) : (string)$contenu; |
|
| 126 | 126 | } |
| 127 | 127 | |
| 128 | 128 | |
@@ -147,48 +147,48 @@ discard block |
||
| 147 | 147 | * true si l'opération a réussie, false sinon. |
| 148 | 148 | **/ |
| 149 | 149 | function lire_fichier($fichier, &$contenu, $options = array()) { |
| 150 | - $contenu = ''; |
|
| 151 | - // inutile car si le fichier n'existe pas, le lock va renvoyer false juste apres |
|
| 152 | - // economisons donc les acces disque, sauf chez free qui rale pour un rien |
|
| 153 | - if (_TEST_FILE_EXISTS and !@file_exists($fichier)) { |
|
| 154 | - return false; |
|
| 155 | - } |
|
| 156 | - |
|
| 157 | - #spip_timer('lire_fichier'); |
|
| 158 | - |
|
| 159 | - // pas de @ sur spip_fopen_lock qui est silencieux de toute facon |
|
| 160 | - if ($fl = spip_fopen_lock($fichier, 'r', LOCK_SH)) { |
|
| 161 | - // lire le fichier avant tout |
|
| 162 | - $contenu = spip_file_get_contents($fichier); |
|
| 163 | - |
|
| 164 | - // le fichier a-t-il ete supprime par le locker ? |
|
| 165 | - // on ne verifie que si la tentative de lecture a echoue |
|
| 166 | - // pour discriminer un contenu vide d'un fichier absent |
|
| 167 | - // et eviter un acces disque |
|
| 168 | - if (!$contenu and !@file_exists($fichier)) { |
|
| 169 | - spip_fclose_unlock($fl); |
|
| 170 | - |
|
| 171 | - return false; |
|
| 172 | - } |
|
| 173 | - |
|
| 174 | - // liberer le verrou |
|
| 175 | - spip_fclose_unlock($fl); |
|
| 176 | - |
|
| 177 | - // Verifications |
|
| 178 | - $ok = true; |
|
| 179 | - if (isset($options['phpcheck']) and $options['phpcheck'] == 'oui') { |
|
| 180 | - $ok &= (preg_match(",[?]>\n?$,", $contenu)); |
|
| 181 | - } |
|
| 182 | - |
|
| 183 | - #spip_log("$fread $fichier ".spip_timer('lire_fichier')); |
|
| 184 | - if (!$ok) { |
|
| 185 | - spip_log("echec lecture $fichier"); |
|
| 186 | - } |
|
| 187 | - |
|
| 188 | - return $ok; |
|
| 189 | - } |
|
| 190 | - |
|
| 191 | - return false; |
|
| 150 | + $contenu = ''; |
|
| 151 | + // inutile car si le fichier n'existe pas, le lock va renvoyer false juste apres |
|
| 152 | + // economisons donc les acces disque, sauf chez free qui rale pour un rien |
|
| 153 | + if (_TEST_FILE_EXISTS and !@file_exists($fichier)) { |
|
| 154 | + return false; |
|
| 155 | + } |
|
| 156 | + |
|
| 157 | + #spip_timer('lire_fichier'); |
|
| 158 | + |
|
| 159 | + // pas de @ sur spip_fopen_lock qui est silencieux de toute facon |
|
| 160 | + if ($fl = spip_fopen_lock($fichier, 'r', LOCK_SH)) { |
|
| 161 | + // lire le fichier avant tout |
|
| 162 | + $contenu = spip_file_get_contents($fichier); |
|
| 163 | + |
|
| 164 | + // le fichier a-t-il ete supprime par le locker ? |
|
| 165 | + // on ne verifie que si la tentative de lecture a echoue |
|
| 166 | + // pour discriminer un contenu vide d'un fichier absent |
|
| 167 | + // et eviter un acces disque |
|
| 168 | + if (!$contenu and !@file_exists($fichier)) { |
|
| 169 | + spip_fclose_unlock($fl); |
|
| 170 | + |
|
| 171 | + return false; |
|
| 172 | + } |
|
| 173 | + |
|
| 174 | + // liberer le verrou |
|
| 175 | + spip_fclose_unlock($fl); |
|
| 176 | + |
|
| 177 | + // Verifications |
|
| 178 | + $ok = true; |
|
| 179 | + if (isset($options['phpcheck']) and $options['phpcheck'] == 'oui') { |
|
| 180 | + $ok &= (preg_match(",[?]>\n?$,", $contenu)); |
|
| 181 | + } |
|
| 182 | + |
|
| 183 | + #spip_log("$fread $fichier ".spip_timer('lire_fichier')); |
|
| 184 | + if (!$ok) { |
|
| 185 | + spip_log("echec lecture $fichier"); |
|
| 186 | + } |
|
| 187 | + |
|
| 188 | + return $ok; |
|
| 189 | + } |
|
| 190 | + |
|
| 191 | + return false; |
|
| 192 | 192 | } |
| 193 | 193 | |
| 194 | 194 | |
@@ -216,85 +216,85 @@ discard block |
||
| 216 | 216 | **/ |
| 217 | 217 | function ecrire_fichier($fichier, $contenu, $ignorer_echec = false, $truncate = true) { |
| 218 | 218 | |
| 219 | - #spip_timer('ecrire_fichier'); |
|
| 220 | - |
|
| 221 | - // verrouiller le fichier destination |
|
| 222 | - if ($fp = spip_fopen_lock($fichier, 'a', LOCK_EX)) { |
|
| 223 | - // ecrire les donnees, compressees le cas echeant |
|
| 224 | - // (on ouvre un nouveau pointeur sur le fichier, ce qui a l'avantage |
|
| 225 | - // de le recreer si le locker qui nous precede l'avait supprime...) |
|
| 226 | - if (substr($fichier, -3) == '.gz') { |
|
| 227 | - $contenu = gzencode($contenu); |
|
| 228 | - } |
|
| 229 | - // si c'est une ecriture avec troncation , on fait plutot une ecriture complete a cote suivie unlink+rename |
|
| 230 | - // pour etre sur d'avoir une operation atomique |
|
| 231 | - // y compris en NFS : http://www.ietf.org/rfc/rfc1094.txt |
|
| 232 | - // sauf sous wintruc ou ca ne marche pas |
|
| 233 | - $ok = false; |
|
| 234 | - if ($truncate and _OS_SERVEUR != 'windows') { |
|
| 235 | - if (!function_exists('creer_uniqid')) { |
|
| 236 | - include_spip('inc/acces'); |
|
| 237 | - } |
|
| 238 | - $id = creer_uniqid(); |
|
| 239 | - // on ouvre un pointeur sur un fichier temporaire en ecriture +raz |
|
| 240 | - if ($fp2 = spip_fopen_lock("$fichier.$id", 'w', LOCK_EX)) { |
|
| 241 | - $s = @fputs($fp2, $contenu, $a = strlen($contenu)); |
|
| 242 | - $ok = ($s == $a); |
|
| 243 | - spip_fclose_unlock($fp2); |
|
| 244 | - spip_fclose_unlock($fp); |
|
| 245 | - // unlink direct et pas spip_unlink car on avait deja le verrou |
|
| 246 | - // a priori pas besoin car rename ecrase la cible |
|
| 247 | - // @unlink($fichier); |
|
| 248 | - // le rename aussitot, atomique quand on est pas sous windows |
|
| 249 | - // au pire on arrive en second en cas de concourance, et le rename echoue |
|
| 250 | - // --> on a la version de l'autre process qui doit etre identique |
|
| 251 | - @rename("$fichier.$id", $fichier); |
|
| 252 | - // precaution en cas d'echec du rename |
|
| 253 | - if (!_TEST_FILE_EXISTS or @file_exists("$fichier.$id")) { |
|
| 254 | - @unlink("$fichier.$id"); |
|
| 255 | - } |
|
| 256 | - if ($ok) { |
|
| 257 | - $ok = file_exists($fichier); |
|
| 258 | - } |
|
| 259 | - } else // echec mais penser a fermer .. |
|
| 260 | - { |
|
| 261 | - spip_fclose_unlock($fp); |
|
| 262 | - } |
|
| 263 | - } |
|
| 264 | - // sinon ou si methode precedente a echoueee |
|
| 265 | - // on se rabat sur la methode ancienne |
|
| 266 | - if (!$ok) { |
|
| 267 | - // ici on est en ajout ou sous windows, cas desespere |
|
| 268 | - if ($truncate) { |
|
| 269 | - @ftruncate($fp, 0); |
|
| 270 | - } |
|
| 271 | - $s = @fputs($fp, $contenu, $a = strlen($contenu)); |
|
| 272 | - |
|
| 273 | - $ok = ($s == $a); |
|
| 274 | - spip_fclose_unlock($fp); |
|
| 275 | - } |
|
| 276 | - |
|
| 277 | - // liberer le verrou et fermer le fichier |
|
| 278 | - @chmod($fichier, _SPIP_CHMOD & 0666); |
|
| 279 | - if ($ok) { |
|
| 280 | - if (strpos($fichier, ".php") !== false) { |
|
| 281 | - spip_clear_opcode_cache(realpath($fichier)); |
|
| 282 | - } |
|
| 283 | - |
|
| 284 | - return $ok; |
|
| 285 | - } |
|
| 286 | - } |
|
| 287 | - |
|
| 288 | - if (!$ignorer_echec) { |
|
| 289 | - include_spip('inc/autoriser'); |
|
| 290 | - if (autoriser('chargerftp')) { |
|
| 291 | - raler_fichier($fichier); |
|
| 292 | - } |
|
| 293 | - spip_unlink($fichier); |
|
| 294 | - } |
|
| 295 | - spip_log("Ecriture fichier $fichier impossible", _LOG_INFO_IMPORTANTE); |
|
| 296 | - |
|
| 297 | - return false; |
|
| 219 | + #spip_timer('ecrire_fichier'); |
|
| 220 | + |
|
| 221 | + // verrouiller le fichier destination |
|
| 222 | + if ($fp = spip_fopen_lock($fichier, 'a', LOCK_EX)) { |
|
| 223 | + // ecrire les donnees, compressees le cas echeant |
|
| 224 | + // (on ouvre un nouveau pointeur sur le fichier, ce qui a l'avantage |
|
| 225 | + // de le recreer si le locker qui nous precede l'avait supprime...) |
|
| 226 | + if (substr($fichier, -3) == '.gz') { |
|
| 227 | + $contenu = gzencode($contenu); |
|
| 228 | + } |
|
| 229 | + // si c'est une ecriture avec troncation , on fait plutot une ecriture complete a cote suivie unlink+rename |
|
| 230 | + // pour etre sur d'avoir une operation atomique |
|
| 231 | + // y compris en NFS : http://www.ietf.org/rfc/rfc1094.txt |
|
| 232 | + // sauf sous wintruc ou ca ne marche pas |
|
| 233 | + $ok = false; |
|
| 234 | + if ($truncate and _OS_SERVEUR != 'windows') { |
|
| 235 | + if (!function_exists('creer_uniqid')) { |
|
| 236 | + include_spip('inc/acces'); |
|
| 237 | + } |
|
| 238 | + $id = creer_uniqid(); |
|
| 239 | + // on ouvre un pointeur sur un fichier temporaire en ecriture +raz |
|
| 240 | + if ($fp2 = spip_fopen_lock("$fichier.$id", 'w', LOCK_EX)) { |
|
| 241 | + $s = @fputs($fp2, $contenu, $a = strlen($contenu)); |
|
| 242 | + $ok = ($s == $a); |
|
| 243 | + spip_fclose_unlock($fp2); |
|
| 244 | + spip_fclose_unlock($fp); |
|
| 245 | + // unlink direct et pas spip_unlink car on avait deja le verrou |
|
| 246 | + // a priori pas besoin car rename ecrase la cible |
|
| 247 | + // @unlink($fichier); |
|
| 248 | + // le rename aussitot, atomique quand on est pas sous windows |
|
| 249 | + // au pire on arrive en second en cas de concourance, et le rename echoue |
|
| 250 | + // --> on a la version de l'autre process qui doit etre identique |
|
| 251 | + @rename("$fichier.$id", $fichier); |
|
| 252 | + // precaution en cas d'echec du rename |
|
| 253 | + if (!_TEST_FILE_EXISTS or @file_exists("$fichier.$id")) { |
|
| 254 | + @unlink("$fichier.$id"); |
|
| 255 | + } |
|
| 256 | + if ($ok) { |
|
| 257 | + $ok = file_exists($fichier); |
|
| 258 | + } |
|
| 259 | + } else // echec mais penser a fermer .. |
|
| 260 | + { |
|
| 261 | + spip_fclose_unlock($fp); |
|
| 262 | + } |
|
| 263 | + } |
|
| 264 | + // sinon ou si methode precedente a echoueee |
|
| 265 | + // on se rabat sur la methode ancienne |
|
| 266 | + if (!$ok) { |
|
| 267 | + // ici on est en ajout ou sous windows, cas desespere |
|
| 268 | + if ($truncate) { |
|
| 269 | + @ftruncate($fp, 0); |
|
| 270 | + } |
|
| 271 | + $s = @fputs($fp, $contenu, $a = strlen($contenu)); |
|
| 272 | + |
|
| 273 | + $ok = ($s == $a); |
|
| 274 | + spip_fclose_unlock($fp); |
|
| 275 | + } |
|
| 276 | + |
|
| 277 | + // liberer le verrou et fermer le fichier |
|
| 278 | + @chmod($fichier, _SPIP_CHMOD & 0666); |
|
| 279 | + if ($ok) { |
|
| 280 | + if (strpos($fichier, ".php") !== false) { |
|
| 281 | + spip_clear_opcode_cache(realpath($fichier)); |
|
| 282 | + } |
|
| 283 | + |
|
| 284 | + return $ok; |
|
| 285 | + } |
|
| 286 | + } |
|
| 287 | + |
|
| 288 | + if (!$ignorer_echec) { |
|
| 289 | + include_spip('inc/autoriser'); |
|
| 290 | + if (autoriser('chargerftp')) { |
|
| 291 | + raler_fichier($fichier); |
|
| 292 | + } |
|
| 293 | + spip_unlink($fichier); |
|
| 294 | + } |
|
| 295 | + spip_log("Ecriture fichier $fichier impossible", _LOG_INFO_IMPORTANTE); |
|
| 296 | + |
|
| 297 | + return false; |
|
| 298 | 298 | } |
| 299 | 299 | |
| 300 | 300 | /** |
@@ -314,12 +314,12 @@ discard block |
||
| 314 | 314 | * Écriture avec troncation ? |
| 315 | 315 | */ |
| 316 | 316 | function ecrire_fichier_securise($fichier, $contenu, $ecrire_quand_meme = false, $truncate = true) { |
| 317 | - if (substr($fichier, -4) !== '.php') { |
|
| 318 | - spip_log('Erreur de programmation: ' . $fichier . ' doit finir par .php'); |
|
| 319 | - } |
|
| 320 | - $contenu = "<" . "?php die ('Acces interdit'); ?" . ">\n" . $contenu; |
|
| 317 | + if (substr($fichier, -4) !== '.php') { |
|
| 318 | + spip_log('Erreur de programmation: ' . $fichier . ' doit finir par .php'); |
|
| 319 | + } |
|
| 320 | + $contenu = "<" . "?php die ('Acces interdit'); ?" . ">\n" . $contenu; |
|
| 321 | 321 | |
| 322 | - return ecrire_fichier($fichier, $contenu, $ecrire_quand_meme, $truncate); |
|
| 322 | + return ecrire_fichier($fichier, $contenu, $ecrire_quand_meme, $truncate); |
|
| 323 | 323 | } |
| 324 | 324 | |
| 325 | 325 | |
@@ -330,23 +330,23 @@ discard block |
||
| 330 | 330 | * @return bool |
| 331 | 331 | */ |
| 332 | 332 | function ecrire_fichier_calcule_si_modifie($fichier, $contenu, $force=false, $use_copy=false) { |
| 333 | - $fichier_tmp = $fichier . '.last'; |
|
| 334 | - if (!ecrire_fichier($fichier_tmp, $contenu, true)){ |
|
| 335 | - return false; |
|
| 336 | - } |
|
| 337 | - if ($force |
|
| 338 | - or !file_exists($fichier) |
|
| 339 | - or md5_file($fichier) != md5_file($fichier_tmp)) { |
|
| 340 | - if ($use_copy) { |
|
| 341 | - @copy($fichier_tmp, $fichier); |
|
| 342 | - } |
|
| 343 | - else { |
|
| 344 | - @rename($fichier_tmp, $fichier); |
|
| 345 | - } |
|
| 346 | - // eviter que PHP ne reserve le vieux timestamp |
|
| 347 | - clearstatcache(true, $fichier); |
|
| 348 | - } |
|
| 349 | - return true; |
|
| 333 | + $fichier_tmp = $fichier . '.last'; |
|
| 334 | + if (!ecrire_fichier($fichier_tmp, $contenu, true)){ |
|
| 335 | + return false; |
|
| 336 | + } |
|
| 337 | + if ($force |
|
| 338 | + or !file_exists($fichier) |
|
| 339 | + or md5_file($fichier) != md5_file($fichier_tmp)) { |
|
| 340 | + if ($use_copy) { |
|
| 341 | + @copy($fichier_tmp, $fichier); |
|
| 342 | + } |
|
| 343 | + else { |
|
| 344 | + @rename($fichier_tmp, $fichier); |
|
| 345 | + } |
|
| 346 | + // eviter que PHP ne reserve le vieux timestamp |
|
| 347 | + clearstatcache(true, $fichier); |
|
| 348 | + } |
|
| 349 | + return true; |
|
| 350 | 350 | } |
| 351 | 351 | |
| 352 | 352 | |
@@ -367,11 +367,11 @@ discard block |
||
| 367 | 367 | * true si l'opération a réussie, false sinon. |
| 368 | 368 | */ |
| 369 | 369 | function lire_fichier_securise($fichier, &$contenu, $options = array()) { |
| 370 | - if ($res = lire_fichier($fichier, $contenu, $options)) { |
|
| 371 | - $contenu = substr($contenu, strlen("<" . "?php die ('Acces interdit'); ?" . ">\n")); |
|
| 372 | - } |
|
| 370 | + if ($res = lire_fichier($fichier, $contenu, $options)) { |
|
| 371 | + $contenu = substr($contenu, strlen("<" . "?php die ('Acces interdit'); ?" . ">\n")); |
|
| 372 | + } |
|
| 373 | 373 | |
| 374 | - return $res; |
|
| 374 | + return $res; |
|
| 375 | 375 | } |
| 376 | 376 | |
| 377 | 377 | /** |
@@ -386,20 +386,20 @@ discard block |
||
| 386 | 386 | * Chemin du fichier |
| 387 | 387 | **/ |
| 388 | 388 | function raler_fichier($fichier) { |
| 389 | - include_spip('inc/minipres'); |
|
| 390 | - $dir = dirname($fichier); |
|
| 391 | - http_status(401); |
|
| 392 | - echo minipres(_T('texte_inc_meta_2'), "<h4 style='color: red'>" |
|
| 393 | - . _T('texte_inc_meta_1', array('fichier' => $fichier)) |
|
| 394 | - . " <a href='" |
|
| 395 | - . generer_url_ecrire('install', "etape=chmod&test_dir=$dir") |
|
| 396 | - . "'>" |
|
| 397 | - . _T('texte_inc_meta_2') |
|
| 398 | - . "</a> " |
|
| 399 | - . _T('texte_inc_meta_3', |
|
| 400 | - array('repertoire' => joli_repertoire($dir))) |
|
| 401 | - . "</h4>\n"); |
|
| 402 | - exit; |
|
| 389 | + include_spip('inc/minipres'); |
|
| 390 | + $dir = dirname($fichier); |
|
| 391 | + http_status(401); |
|
| 392 | + echo minipres(_T('texte_inc_meta_2'), "<h4 style='color: red'>" |
|
| 393 | + . _T('texte_inc_meta_1', array('fichier' => $fichier)) |
|
| 394 | + . " <a href='" |
|
| 395 | + . generer_url_ecrire('install', "etape=chmod&test_dir=$dir") |
|
| 396 | + . "'>" |
|
| 397 | + . _T('texte_inc_meta_2') |
|
| 398 | + . "</a> " |
|
| 399 | + . _T('texte_inc_meta_3', |
|
| 400 | + array('repertoire' => joli_repertoire($dir))) |
|
| 401 | + . "</h4>\n"); |
|
| 402 | + exit; |
|
| 403 | 403 | } |
| 404 | 404 | |
| 405 | 405 | |
@@ -414,14 +414,14 @@ discard block |
||
| 414 | 414 | * - true si récent, false sinon |
| 415 | 415 | */ |
| 416 | 416 | function jeune_fichier($fichier, $n) { |
| 417 | - if (!file_exists($fichier)) { |
|
| 418 | - return false; |
|
| 419 | - } |
|
| 420 | - if (!$c = @filemtime($fichier)) { |
|
| 421 | - return false; |
|
| 422 | - } |
|
| 423 | - |
|
| 424 | - return (time() - $n <= $c); |
|
| 417 | + if (!file_exists($fichier)) { |
|
| 418 | + return false; |
|
| 419 | + } |
|
| 420 | + if (!$c = @filemtime($fichier)) { |
|
| 421 | + return false; |
|
| 422 | + } |
|
| 423 | + |
|
| 424 | + return (time() - $n <= $c); |
|
| 425 | 425 | } |
| 426 | 426 | |
| 427 | 427 | /** |
@@ -436,22 +436,22 @@ discard block |
||
| 436 | 436 | * - false si on n'arrive pas poser le verrou ou si la suppression échoue |
| 437 | 437 | */ |
| 438 | 438 | function supprimer_fichier($fichier, $lock = true) { |
| 439 | - if (!@file_exists($fichier)) { |
|
| 440 | - return true; |
|
| 441 | - } |
|
| 442 | - |
|
| 443 | - if ($lock) { |
|
| 444 | - // verrouiller le fichier destination |
|
| 445 | - if (!$fp = spip_fopen_lock($fichier, 'a', LOCK_EX)) { |
|
| 446 | - return false; |
|
| 447 | - } |
|
| 448 | - |
|
| 449 | - // liberer le verrou |
|
| 450 | - spip_fclose_unlock($fp); |
|
| 451 | - } |
|
| 452 | - |
|
| 453 | - // supprimer |
|
| 454 | - return @unlink($fichier); |
|
| 439 | + if (!@file_exists($fichier)) { |
|
| 440 | + return true; |
|
| 441 | + } |
|
| 442 | + |
|
| 443 | + if ($lock) { |
|
| 444 | + // verrouiller le fichier destination |
|
| 445 | + if (!$fp = spip_fopen_lock($fichier, 'a', LOCK_EX)) { |
|
| 446 | + return false; |
|
| 447 | + } |
|
| 448 | + |
|
| 449 | + // liberer le verrou |
|
| 450 | + spip_fclose_unlock($fp); |
|
| 451 | + } |
|
| 452 | + |
|
| 453 | + // supprimer |
|
| 454 | + return @unlink($fichier); |
|
| 455 | 455 | } |
| 456 | 456 | |
| 457 | 457 | /** |
@@ -461,12 +461,12 @@ discard block |
||
| 461 | 461 | * Chemin du fichier |
| 462 | 462 | */ |
| 463 | 463 | function spip_unlink($f) { |
| 464 | - if (!is_dir($f)) { |
|
| 465 | - supprimer_fichier($f, false); |
|
| 466 | - } else { |
|
| 467 | - @unlink("$f/.ok"); |
|
| 468 | - @rmdir($f); |
|
| 469 | - } |
|
| 464 | + if (!is_dir($f)) { |
|
| 465 | + supprimer_fichier($f, false); |
|
| 466 | + } else { |
|
| 467 | + @unlink("$f/.ok"); |
|
| 468 | + @rmdir($f); |
|
| 469 | + } |
|
| 470 | 470 | } |
| 471 | 471 | |
| 472 | 472 | /** |
@@ -480,26 +480,26 @@ discard block |
||
| 480 | 480 | * The absolute path of the PHP file to invalidate. |
| 481 | 481 | */ |
| 482 | 482 | function spip_clear_opcode_cache($filepath) { |
| 483 | - clearstatcache(true, $filepath); |
|
| 484 | - |
|
| 485 | - // Zend OPcache |
|
| 486 | - if (function_exists('opcache_invalidate')) { |
|
| 487 | - $invalidate = @opcache_invalidate($filepath, true); |
|
| 488 | - // si l'invalidation a echoue lever un flag |
|
| 489 | - if (!$invalidate and !defined('_spip_attend_invalidation_opcode_cache')) { |
|
| 490 | - define('_spip_attend_invalidation_opcode_cache',true); |
|
| 491 | - } |
|
| 492 | - } elseif (!defined('_spip_attend_invalidation_opcode_cache')) { |
|
| 493 | - // n'agira que si opcache est effectivement actif (il semble qu'on a pas toujours la fonction opcache_invalidate) |
|
| 494 | - define('_spip_attend_invalidation_opcode_cache',true); |
|
| 495 | - } |
|
| 496 | - // APC. |
|
| 497 | - if (function_exists('apc_delete_file')) { |
|
| 498 | - // apc_delete_file() throws a PHP warning in case the specified file was |
|
| 499 | - // not compiled yet. |
|
| 500 | - // @see http://php.net/apc-delete-file |
|
| 501 | - @apc_delete_file($filepath); |
|
| 502 | - } |
|
| 483 | + clearstatcache(true, $filepath); |
|
| 484 | + |
|
| 485 | + // Zend OPcache |
|
| 486 | + if (function_exists('opcache_invalidate')) { |
|
| 487 | + $invalidate = @opcache_invalidate($filepath, true); |
|
| 488 | + // si l'invalidation a echoue lever un flag |
|
| 489 | + if (!$invalidate and !defined('_spip_attend_invalidation_opcode_cache')) { |
|
| 490 | + define('_spip_attend_invalidation_opcode_cache',true); |
|
| 491 | + } |
|
| 492 | + } elseif (!defined('_spip_attend_invalidation_opcode_cache')) { |
|
| 493 | + // n'agira que si opcache est effectivement actif (il semble qu'on a pas toujours la fonction opcache_invalidate) |
|
| 494 | + define('_spip_attend_invalidation_opcode_cache',true); |
|
| 495 | + } |
|
| 496 | + // APC. |
|
| 497 | + if (function_exists('apc_delete_file')) { |
|
| 498 | + // apc_delete_file() throws a PHP warning in case the specified file was |
|
| 499 | + // not compiled yet. |
|
| 500 | + // @see http://php.net/apc-delete-file |
|
| 501 | + @apc_delete_file($filepath); |
|
| 502 | + } |
|
| 503 | 503 | } |
| 504 | 504 | |
| 505 | 505 | /** |
@@ -522,24 +522,24 @@ discard block |
||
| 522 | 522 | * |
| 523 | 523 | */ |
| 524 | 524 | function spip_attend_invalidation_opcode_cache($timestamp = null) { |
| 525 | - if (function_exists('opcache_get_configuration') |
|
| 526 | - and @ini_get('opcache.enable') |
|
| 527 | - and @ini_get('opcache.validate_timestamps') |
|
| 528 | - and ($duree = intval(@ini_get('opcache.revalidate_freq')) or $duree = 2) |
|
| 529 | - and defined('_spip_attend_invalidation_opcode_cache') // des invalidations ont echouees |
|
| 530 | - ) { |
|
| 531 | - $wait = $duree + 1; |
|
| 532 | - if ($timestamp) { |
|
| 533 | - $wait -= (time() - $timestamp); |
|
| 534 | - if ($wait<0) { |
|
| 535 | - $wait = 0; |
|
| 536 | - } |
|
| 537 | - } |
|
| 538 | - spip_log('Probleme de configuration opcache.revalidate_freq '. $duree .'s : on attend '.$wait.'s', _LOG_INFO_IMPORTANTE); |
|
| 539 | - if ($wait) { |
|
| 540 | - sleep($duree + 1); |
|
| 541 | - } |
|
| 542 | - } |
|
| 525 | + if (function_exists('opcache_get_configuration') |
|
| 526 | + and @ini_get('opcache.enable') |
|
| 527 | + and @ini_get('opcache.validate_timestamps') |
|
| 528 | + and ($duree = intval(@ini_get('opcache.revalidate_freq')) or $duree = 2) |
|
| 529 | + and defined('_spip_attend_invalidation_opcode_cache') // des invalidations ont echouees |
|
| 530 | + ) { |
|
| 531 | + $wait = $duree + 1; |
|
| 532 | + if ($timestamp) { |
|
| 533 | + $wait -= (time() - $timestamp); |
|
| 534 | + if ($wait<0) { |
|
| 535 | + $wait = 0; |
|
| 536 | + } |
|
| 537 | + } |
|
| 538 | + spip_log('Probleme de configuration opcache.revalidate_freq '. $duree .'s : on attend '.$wait.'s', _LOG_INFO_IMPORTANTE); |
|
| 539 | + if ($wait) { |
|
| 540 | + sleep($duree + 1); |
|
| 541 | + } |
|
| 542 | + } |
|
| 543 | 543 | } |
| 544 | 544 | |
| 545 | 545 | |
@@ -552,26 +552,26 @@ discard block |
||
| 552 | 552 | * @return bool Suppression reussie. |
| 553 | 553 | */ |
| 554 | 554 | function supprimer_repertoire($dir) { |
| 555 | - if (!file_exists($dir)) { |
|
| 556 | - return true; |
|
| 557 | - } |
|
| 558 | - if (!is_dir($dir) || is_link($dir)) { |
|
| 559 | - return @unlink($dir); |
|
| 560 | - } |
|
| 561 | - |
|
| 562 | - foreach (scandir($dir) as $item) { |
|
| 563 | - if ($item == '.' || $item == '..') { |
|
| 564 | - continue; |
|
| 565 | - } |
|
| 566 | - if (!supprimer_repertoire($dir . "/" . $item)) { |
|
| 567 | - @chmod($dir . "/" . $item, 0777); |
|
| 568 | - if (!supprimer_repertoire($dir . "/" . $item)) { |
|
| 569 | - return false; |
|
| 570 | - } |
|
| 571 | - }; |
|
| 572 | - } |
|
| 573 | - |
|
| 574 | - return @rmdir($dir); |
|
| 555 | + if (!file_exists($dir)) { |
|
| 556 | + return true; |
|
| 557 | + } |
|
| 558 | + if (!is_dir($dir) || is_link($dir)) { |
|
| 559 | + return @unlink($dir); |
|
| 560 | + } |
|
| 561 | + |
|
| 562 | + foreach (scandir($dir) as $item) { |
|
| 563 | + if ($item == '.' || $item == '..') { |
|
| 564 | + continue; |
|
| 565 | + } |
|
| 566 | + if (!supprimer_repertoire($dir . "/" . $item)) { |
|
| 567 | + @chmod($dir . "/" . $item, 0777); |
|
| 568 | + if (!supprimer_repertoire($dir . "/" . $item)) { |
|
| 569 | + return false; |
|
| 570 | + } |
|
| 571 | + }; |
|
| 572 | + } |
|
| 573 | + |
|
| 574 | + return @rmdir($dir); |
|
| 575 | 575 | } |
| 576 | 576 | |
| 577 | 577 | |
@@ -600,57 +600,57 @@ discard block |
||
| 600 | 600 | * Chemin du répertoire créé. |
| 601 | 601 | **/ |
| 602 | 602 | function sous_repertoire($base, $subdir = '', $nobase = false, $tantpis = false) { |
| 603 | - static $dirs = array(); |
|
| 604 | - |
|
| 605 | - $base = str_replace("//", "/", $base); |
|
| 606 | - |
|
| 607 | - # suppr le dernier caractere si c'est un / |
|
| 608 | - $base = rtrim($base, '/'); |
|
| 609 | - |
|
| 610 | - if (!strlen($subdir)) { |
|
| 611 | - $n = strrpos($base, "/"); |
|
| 612 | - if ($n === false) { |
|
| 613 | - return $nobase ? '' : ($base . '/'); |
|
| 614 | - } |
|
| 615 | - $subdir = substr($base, $n + 1); |
|
| 616 | - $base = substr($base, 0, $n + 1); |
|
| 617 | - } else { |
|
| 618 | - $base .= '/'; |
|
| 619 | - $subdir = str_replace("/", "", $subdir); |
|
| 620 | - } |
|
| 621 | - |
|
| 622 | - $baseaff = $nobase ? '' : $base; |
|
| 623 | - if (isset($dirs[$base . $subdir])) { |
|
| 624 | - return $baseaff . $dirs[$base . $subdir]; |
|
| 625 | - } |
|
| 626 | - |
|
| 627 | - $path = $base . $subdir; # $path = 'IMG/distant/pdf' ou 'IMG/distant_pdf' |
|
| 628 | - |
|
| 629 | - if (file_exists("$path/.ok")) { |
|
| 630 | - return $baseaff . ($dirs[$base . $subdir] = "$subdir/"); |
|
| 631 | - } |
|
| 632 | - |
|
| 633 | - @mkdir($path, _SPIP_CHMOD); |
|
| 634 | - @chmod($path, _SPIP_CHMOD); |
|
| 635 | - |
|
| 636 | - if (is_dir($path) && is_writable($path)) { |
|
| 637 | - @touch("$path/.ok"); |
|
| 638 | - spip_log("creation $base$subdir/"); |
|
| 639 | - |
|
| 640 | - return $baseaff . ($dirs[$base . $subdir] = "$subdir/"); |
|
| 641 | - } |
|
| 642 | - |
|
| 643 | - // en cas d'echec c'est peut etre tout simplement que le disque est plein : |
|
| 644 | - // l'inode du fichier dir_test existe, mais impossible d'y mettre du contenu |
|
| 645 | - spip_log("echec creation $base${subdir}"); |
|
| 646 | - if ($tantpis) { |
|
| 647 | - return ''; |
|
| 648 | - } |
|
| 649 | - if (!_DIR_RESTREINT) { |
|
| 650 | - $base = preg_replace(',^' . _DIR_RACINE . ',', '', $base); |
|
| 651 | - } |
|
| 652 | - $base .= $subdir; |
|
| 653 | - raler_fichier($base . '/.ok'); |
|
| 603 | + static $dirs = array(); |
|
| 604 | + |
|
| 605 | + $base = str_replace("//", "/", $base); |
|
| 606 | + |
|
| 607 | + # suppr le dernier caractere si c'est un / |
|
| 608 | + $base = rtrim($base, '/'); |
|
| 609 | + |
|
| 610 | + if (!strlen($subdir)) { |
|
| 611 | + $n = strrpos($base, "/"); |
|
| 612 | + if ($n === false) { |
|
| 613 | + return $nobase ? '' : ($base . '/'); |
|
| 614 | + } |
|
| 615 | + $subdir = substr($base, $n + 1); |
|
| 616 | + $base = substr($base, 0, $n + 1); |
|
| 617 | + } else { |
|
| 618 | + $base .= '/'; |
|
| 619 | + $subdir = str_replace("/", "", $subdir); |
|
| 620 | + } |
|
| 621 | + |
|
| 622 | + $baseaff = $nobase ? '' : $base; |
|
| 623 | + if (isset($dirs[$base . $subdir])) { |
|
| 624 | + return $baseaff . $dirs[$base . $subdir]; |
|
| 625 | + } |
|
| 626 | + |
|
| 627 | + $path = $base . $subdir; # $path = 'IMG/distant/pdf' ou 'IMG/distant_pdf' |
|
| 628 | + |
|
| 629 | + if (file_exists("$path/.ok")) { |
|
| 630 | + return $baseaff . ($dirs[$base . $subdir] = "$subdir/"); |
|
| 631 | + } |
|
| 632 | + |
|
| 633 | + @mkdir($path, _SPIP_CHMOD); |
|
| 634 | + @chmod($path, _SPIP_CHMOD); |
|
| 635 | + |
|
| 636 | + if (is_dir($path) && is_writable($path)) { |
|
| 637 | + @touch("$path/.ok"); |
|
| 638 | + spip_log("creation $base$subdir/"); |
|
| 639 | + |
|
| 640 | + return $baseaff . ($dirs[$base . $subdir] = "$subdir/"); |
|
| 641 | + } |
|
| 642 | + |
|
| 643 | + // en cas d'echec c'est peut etre tout simplement que le disque est plein : |
|
| 644 | + // l'inode du fichier dir_test existe, mais impossible d'y mettre du contenu |
|
| 645 | + spip_log("echec creation $base${subdir}"); |
|
| 646 | + if ($tantpis) { |
|
| 647 | + return ''; |
|
| 648 | + } |
|
| 649 | + if (!_DIR_RESTREINT) { |
|
| 650 | + $base = preg_replace(',^' . _DIR_RACINE . ',', '', $base); |
|
| 651 | + } |
|
| 652 | + $base .= $subdir; |
|
| 653 | + raler_fichier($base . '/.ok'); |
|
| 654 | 654 | } |
| 655 | 655 | |
| 656 | 656 | |
@@ -683,51 +683,51 @@ discard block |
||
| 683 | 683 | * Chemins des fichiers trouvés. |
| 684 | 684 | **/ |
| 685 | 685 | function preg_files($dir, $pattern = -1 /* AUTO */, $maxfiles = 10000, $recurs = array()) { |
| 686 | - $nbfiles = 0; |
|
| 687 | - if ($pattern == -1) { |
|
| 688 | - $pattern = "^$dir"; |
|
| 689 | - } |
|
| 690 | - $fichiers = array(); |
|
| 691 | - // revenir au repertoire racine si on a recu dossier/truc |
|
| 692 | - // pour regarder dossier/truc/ ne pas oublier le / final |
|
| 693 | - $dir = preg_replace(',/[^/]*$,', '', $dir); |
|
| 694 | - if ($dir == '') { |
|
| 695 | - $dir = '.'; |
|
| 696 | - } |
|
| 697 | - |
|
| 698 | - if (@is_dir($dir) and is_readable($dir) and $d = opendir($dir)) { |
|
| 699 | - while (($f = readdir($d)) !== false && ($nbfiles < $maxfiles)) { |
|
| 700 | - if ($f[0] != '.' # ignorer . .. .svn etc |
|
| 701 | - and $f != 'CVS' |
|
| 702 | - and $f != 'remove.txt' |
|
| 703 | - and is_readable($f = "$dir/$f") |
|
| 704 | - ) { |
|
| 705 | - if (is_file($f)) { |
|
| 706 | - if (preg_match(";$pattern;iS", $f)) { |
|
| 707 | - $fichiers[] = $f; |
|
| 708 | - $nbfiles++; |
|
| 709 | - } |
|
| 710 | - } else { |
|
| 711 | - if (is_dir($f) and is_array($recurs)) { |
|
| 712 | - $rp = @realpath($f); |
|
| 713 | - if (!is_string($rp) or !strlen($rp)) { |
|
| 714 | - $rp = $f; |
|
| 715 | - } # realpath n'est peut etre pas autorise |
|
| 716 | - if (!isset($recurs[$rp])) { |
|
| 717 | - $recurs[$rp] = true; |
|
| 718 | - $beginning = $fichiers; |
|
| 719 | - $end = preg_files("$f/", $pattern, |
|
| 720 | - $maxfiles - $nbfiles, $recurs); |
|
| 721 | - $fichiers = array_merge((array)$beginning, (array)$end); |
|
| 722 | - $nbfiles = count($fichiers); |
|
| 723 | - } |
|
| 724 | - } |
|
| 725 | - } |
|
| 726 | - } |
|
| 727 | - } |
|
| 728 | - closedir($d); |
|
| 729 | - } |
|
| 730 | - sort($fichiers); |
|
| 731 | - |
|
| 732 | - return $fichiers; |
|
| 686 | + $nbfiles = 0; |
|
| 687 | + if ($pattern == -1) { |
|
| 688 | + $pattern = "^$dir"; |
|
| 689 | + } |
|
| 690 | + $fichiers = array(); |
|
| 691 | + // revenir au repertoire racine si on a recu dossier/truc |
|
| 692 | + // pour regarder dossier/truc/ ne pas oublier le / final |
|
| 693 | + $dir = preg_replace(',/[^/]*$,', '', $dir); |
|
| 694 | + if ($dir == '') { |
|
| 695 | + $dir = '.'; |
|
| 696 | + } |
|
| 697 | + |
|
| 698 | + if (@is_dir($dir) and is_readable($dir) and $d = opendir($dir)) { |
|
| 699 | + while (($f = readdir($d)) !== false && ($nbfiles < $maxfiles)) { |
|
| 700 | + if ($f[0] != '.' # ignorer . .. .svn etc |
|
| 701 | + and $f != 'CVS' |
|
| 702 | + and $f != 'remove.txt' |
|
| 703 | + and is_readable($f = "$dir/$f") |
|
| 704 | + ) { |
|
| 705 | + if (is_file($f)) { |
|
| 706 | + if (preg_match(";$pattern;iS", $f)) { |
|
| 707 | + $fichiers[] = $f; |
|
| 708 | + $nbfiles++; |
|
| 709 | + } |
|
| 710 | + } else { |
|
| 711 | + if (is_dir($f) and is_array($recurs)) { |
|
| 712 | + $rp = @realpath($f); |
|
| 713 | + if (!is_string($rp) or !strlen($rp)) { |
|
| 714 | + $rp = $f; |
|
| 715 | + } # realpath n'est peut etre pas autorise |
|
| 716 | + if (!isset($recurs[$rp])) { |
|
| 717 | + $recurs[$rp] = true; |
|
| 718 | + $beginning = $fichiers; |
|
| 719 | + $end = preg_files("$f/", $pattern, |
|
| 720 | + $maxfiles - $nbfiles, $recurs); |
|
| 721 | + $fichiers = array_merge((array)$beginning, (array)$end); |
|
| 722 | + $nbfiles = count($fichiers); |
|
| 723 | + } |
|
| 724 | + } |
|
| 725 | + } |
|
| 726 | + } |
|
| 727 | + } |
|
| 728 | + closedir($d); |
|
| 729 | + } |
|
| 730 | + sort($fichiers); |
|
| 731 | + |
|
| 732 | + return $fichiers; |
|
| 733 | 733 | } |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | \***************************************************************************/ |
| 12 | 12 | |
| 13 | 13 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 14 | - return; |
|
| 14 | + return; |
|
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | include_spip('public/decompiler'); |
@@ -66,135 +66,135 @@ discard block |
||
| 66 | 66 | * - string si $message à false. |
| 67 | 67 | **/ |
| 68 | 68 | function public_debusquer_dist($message = '', $lieu = '', $opt = array()) { |
| 69 | - static $tableau_des_erreurs = array(); |
|
| 70 | - |
|
| 71 | - // Pour des tests unitaires, pouvoir récupérer les erreurs générées |
|
| 72 | - if (isset($opt['erreurs'])) { |
|
| 73 | - if ($opt['erreurs'] == 'get') { |
|
| 74 | - return $tableau_des_erreurs; |
|
| 75 | - } |
|
| 76 | - if ($opt['erreurs'] == 'reset') { |
|
| 77 | - $tableau_des_erreurs = array(); |
|
| 78 | - |
|
| 79 | - return true; |
|
| 80 | - } |
|
| 81 | - } |
|
| 82 | - |
|
| 83 | - // Erreur ou appel final ? |
|
| 84 | - if ($message) { |
|
| 85 | - $message = debusquer_compose_message($message); |
|
| 86 | - $tableau_des_erreurs[] = array($message, $lieu); |
|
| 87 | - set_request('var_mode', 'debug'); |
|
| 88 | - $GLOBALS['bouton_admin_debug'] = true; |
|
| 89 | - // Permettre a la compil de continuer |
|
| 90 | - if (is_object($lieu) and (!isset($lieu->code) or !$lieu->code)) { |
|
| 91 | - $lieu->code = "''"; |
|
| 92 | - } |
|
| 93 | - // forcer l'appel au debusqueur en cas de boucles infernales |
|
| 94 | - $urgence = (_DEBUG_MAX_SQUELETTE_ERREURS and count($tableau_des_erreurs) > _DEBUG_MAX_SQUELETTE_ERREURS); |
|
| 95 | - if (!$urgence) { |
|
| 96 | - return; |
|
| 97 | - } |
|
| 98 | - } |
|
| 99 | - if (empty($GLOBALS['debug_objets']['principal'])) { |
|
| 100 | - // espace public ? |
|
| 101 | - if (isset($GLOBALS['fond'])) { |
|
| 102 | - $GLOBALS['debug_objets']['principal'] = $GLOBALS['fond']; |
|
| 103 | - } |
|
| 104 | - } |
|
| 105 | - |
|
| 106 | - include_spip('inc/autoriser'); |
|
| 107 | - if (!autoriser('debug')) { |
|
| 108 | - return; |
|
| 109 | - } |
|
| 110 | - include_spip('inc/headers'); |
|
| 111 | - include_spip('inc/filtres'); |
|
| 112 | - |
|
| 113 | - // en cas de squelette inclus, virer le code de l'incluant: |
|
| 114 | - // - il contient souvent une Div restreignant la largeur a 3 fois rien |
|
| 115 | - // - ca fait 2 headers ! |
|
| 116 | - // sauf si l'on se trouve deja dans un flux compresse (plugin compresseur |
|
| 117 | - // actif par exemple) |
|
| 118 | - if (ob_get_length() |
|
| 119 | - and |
|
| 120 | - !in_array('ob_gzhandler', ob_get_status()) |
|
| 121 | - ) { |
|
| 122 | - ob_end_clean(); |
|
| 123 | - } |
|
| 124 | - |
|
| 125 | - lang_select($GLOBALS['visiteur_session']['lang']); |
|
| 126 | - $fonc = _request('var_mode_objet'); |
|
| 127 | - $mode = _request('var_mode_affiche'); |
|
| 128 | - $self = str_replace("\\'", ''', self()); |
|
| 129 | - $self = parametre_url($self, 'var_mode', 'debug'); |
|
| 130 | - |
|
| 131 | - $res = debusquer_bandeau($tableau_des_erreurs) |
|
| 132 | - . '<br />' |
|
| 133 | - . debusquer_squelette($fonc, $mode, $self); |
|
| 134 | - |
|
| 135 | - if (!_DIR_RESTREINT or headers_sent()) { |
|
| 136 | - return $res; |
|
| 137 | - } |
|
| 138 | - if ($tableau_des_erreurs) { |
|
| 139 | - http_status(503); |
|
| 140 | - } |
|
| 141 | - |
|
| 142 | - http_no_cache(); |
|
| 143 | - if (isset($_GET['var_profile'])) { |
|
| 144 | - $titre = parametre_url($GLOBALS['REQUEST_URI'], 'var_profile', ''); |
|
| 145 | - $titre = parametre_url($titre, 'var_mode', ''); |
|
| 146 | - } else { |
|
| 147 | - if (!$fonc) { |
|
| 148 | - $fonc = $GLOBALS['debug_objets']['principal']; |
|
| 149 | - } |
|
| 150 | - $titre = !$mode ? $fonc : ($mode . (isset($GLOBALS['debug_objets']['sourcefile'][$fonc]) ? " " . $GLOBALS['debug_objets']['sourcefile'][$fonc] : "")); |
|
| 151 | - } |
|
| 152 | - if ($message === false) { |
|
| 153 | - lang_select(); |
|
| 154 | - |
|
| 155 | - return debusquer_entete($titre, $res); |
|
| 156 | - } else { |
|
| 157 | - echo debusquer_entete($titre, $res); |
|
| 158 | - } |
|
| 159 | - exit; |
|
| 69 | + static $tableau_des_erreurs = array(); |
|
| 70 | + |
|
| 71 | + // Pour des tests unitaires, pouvoir récupérer les erreurs générées |
|
| 72 | + if (isset($opt['erreurs'])) { |
|
| 73 | + if ($opt['erreurs'] == 'get') { |
|
| 74 | + return $tableau_des_erreurs; |
|
| 75 | + } |
|
| 76 | + if ($opt['erreurs'] == 'reset') { |
|
| 77 | + $tableau_des_erreurs = array(); |
|
| 78 | + |
|
| 79 | + return true; |
|
| 80 | + } |
|
| 81 | + } |
|
| 82 | + |
|
| 83 | + // Erreur ou appel final ? |
|
| 84 | + if ($message) { |
|
| 85 | + $message = debusquer_compose_message($message); |
|
| 86 | + $tableau_des_erreurs[] = array($message, $lieu); |
|
| 87 | + set_request('var_mode', 'debug'); |
|
| 88 | + $GLOBALS['bouton_admin_debug'] = true; |
|
| 89 | + // Permettre a la compil de continuer |
|
| 90 | + if (is_object($lieu) and (!isset($lieu->code) or !$lieu->code)) { |
|
| 91 | + $lieu->code = "''"; |
|
| 92 | + } |
|
| 93 | + // forcer l'appel au debusqueur en cas de boucles infernales |
|
| 94 | + $urgence = (_DEBUG_MAX_SQUELETTE_ERREURS and count($tableau_des_erreurs) > _DEBUG_MAX_SQUELETTE_ERREURS); |
|
| 95 | + if (!$urgence) { |
|
| 96 | + return; |
|
| 97 | + } |
|
| 98 | + } |
|
| 99 | + if (empty($GLOBALS['debug_objets']['principal'])) { |
|
| 100 | + // espace public ? |
|
| 101 | + if (isset($GLOBALS['fond'])) { |
|
| 102 | + $GLOBALS['debug_objets']['principal'] = $GLOBALS['fond']; |
|
| 103 | + } |
|
| 104 | + } |
|
| 105 | + |
|
| 106 | + include_spip('inc/autoriser'); |
|
| 107 | + if (!autoriser('debug')) { |
|
| 108 | + return; |
|
| 109 | + } |
|
| 110 | + include_spip('inc/headers'); |
|
| 111 | + include_spip('inc/filtres'); |
|
| 112 | + |
|
| 113 | + // en cas de squelette inclus, virer le code de l'incluant: |
|
| 114 | + // - il contient souvent une Div restreignant la largeur a 3 fois rien |
|
| 115 | + // - ca fait 2 headers ! |
|
| 116 | + // sauf si l'on se trouve deja dans un flux compresse (plugin compresseur |
|
| 117 | + // actif par exemple) |
|
| 118 | + if (ob_get_length() |
|
| 119 | + and |
|
| 120 | + !in_array('ob_gzhandler', ob_get_status()) |
|
| 121 | + ) { |
|
| 122 | + ob_end_clean(); |
|
| 123 | + } |
|
| 124 | + |
|
| 125 | + lang_select($GLOBALS['visiteur_session']['lang']); |
|
| 126 | + $fonc = _request('var_mode_objet'); |
|
| 127 | + $mode = _request('var_mode_affiche'); |
|
| 128 | + $self = str_replace("\\'", ''', self()); |
|
| 129 | + $self = parametre_url($self, 'var_mode', 'debug'); |
|
| 130 | + |
|
| 131 | + $res = debusquer_bandeau($tableau_des_erreurs) |
|
| 132 | + . '<br />' |
|
| 133 | + . debusquer_squelette($fonc, $mode, $self); |
|
| 134 | + |
|
| 135 | + if (!_DIR_RESTREINT or headers_sent()) { |
|
| 136 | + return $res; |
|
| 137 | + } |
|
| 138 | + if ($tableau_des_erreurs) { |
|
| 139 | + http_status(503); |
|
| 140 | + } |
|
| 141 | + |
|
| 142 | + http_no_cache(); |
|
| 143 | + if (isset($_GET['var_profile'])) { |
|
| 144 | + $titre = parametre_url($GLOBALS['REQUEST_URI'], 'var_profile', ''); |
|
| 145 | + $titre = parametre_url($titre, 'var_mode', ''); |
|
| 146 | + } else { |
|
| 147 | + if (!$fonc) { |
|
| 148 | + $fonc = $GLOBALS['debug_objets']['principal']; |
|
| 149 | + } |
|
| 150 | + $titre = !$mode ? $fonc : ($mode . (isset($GLOBALS['debug_objets']['sourcefile'][$fonc]) ? " " . $GLOBALS['debug_objets']['sourcefile'][$fonc] : "")); |
|
| 151 | + } |
|
| 152 | + if ($message === false) { |
|
| 153 | + lang_select(); |
|
| 154 | + |
|
| 155 | + return debusquer_entete($titre, $res); |
|
| 156 | + } else { |
|
| 157 | + echo debusquer_entete($titre, $res); |
|
| 158 | + } |
|
| 159 | + exit; |
|
| 160 | 160 | } |
| 161 | 161 | |
| 162 | 162 | function debusquer_compose_message($msg) { |
| 163 | - if (is_array($msg)) { |
|
| 164 | - // si c'est un texte, c'est une traduction a faire, mais |
|
| 165 | - // sqlite renvoit aussi des erreurs alpha num (mais avec 3 arguments) |
|
| 166 | - if (!is_numeric($msg[0]) and count($msg) == 2) { |
|
| 167 | - // message avec argument: instancier |
|
| 168 | - $msg = _T($msg[0], $msg[1], 'spip-debug-arg'); |
|
| 169 | - } else { |
|
| 170 | - // message SQL: interpreter |
|
| 171 | - $msg = debusquer_requete($msg); |
|
| 172 | - } |
|
| 173 | - } |
|
| 174 | - // FIXME: le fond n'est pas la si on n'est pas dans un squelette |
|
| 175 | - // cela dit, ca serait bien d'indiquer tout de meme d'ou vient l'erreur |
|
| 176 | - $fond = isset($GLOBALS['fond']) ? $GLOBALS['fond'] : ""; |
|
| 177 | - // une erreur critique sort $message en array |
|
| 178 | - $debug = is_array($msg) ? $msg[1] : $msg; |
|
| 179 | - spip_log("Debug: " . $debug . " (" . $fond . ")"); |
|
| 180 | - |
|
| 181 | - return $msg; |
|
| 163 | + if (is_array($msg)) { |
|
| 164 | + // si c'est un texte, c'est une traduction a faire, mais |
|
| 165 | + // sqlite renvoit aussi des erreurs alpha num (mais avec 3 arguments) |
|
| 166 | + if (!is_numeric($msg[0]) and count($msg) == 2) { |
|
| 167 | + // message avec argument: instancier |
|
| 168 | + $msg = _T($msg[0], $msg[1], 'spip-debug-arg'); |
|
| 169 | + } else { |
|
| 170 | + // message SQL: interpreter |
|
| 171 | + $msg = debusquer_requete($msg); |
|
| 172 | + } |
|
| 173 | + } |
|
| 174 | + // FIXME: le fond n'est pas la si on n'est pas dans un squelette |
|
| 175 | + // cela dit, ca serait bien d'indiquer tout de meme d'ou vient l'erreur |
|
| 176 | + $fond = isset($GLOBALS['fond']) ? $GLOBALS['fond'] : ""; |
|
| 177 | + // une erreur critique sort $message en array |
|
| 178 | + $debug = is_array($msg) ? $msg[1] : $msg; |
|
| 179 | + spip_log("Debug: " . $debug . " (" . $fond . ")"); |
|
| 180 | + |
|
| 181 | + return $msg; |
|
| 182 | 182 | } |
| 183 | 183 | |
| 184 | 184 | function debusquer_bandeau($erreurs) { |
| 185 | 185 | |
| 186 | - if (!empty($erreurs)) { |
|
| 187 | - $n = array(count($erreurs) . ' ' . _T('zbug_erreur_squelette')); |
|
| 186 | + if (!empty($erreurs)) { |
|
| 187 | + $n = array(count($erreurs) . ' ' . _T('zbug_erreur_squelette')); |
|
| 188 | 188 | |
| 189 | - return debusquer_navigation($erreurs, $n); |
|
| 190 | - } elseif (!empty($GLOBALS['tableau_des_temps'])) { |
|
| 191 | - include_spip('public/tracer'); |
|
| 192 | - list($temps, $nav) = chrono_requete($GLOBALS['tableau_des_temps']); |
|
| 189 | + return debusquer_navigation($erreurs, $n); |
|
| 190 | + } elseif (!empty($GLOBALS['tableau_des_temps'])) { |
|
| 191 | + include_spip('public/tracer'); |
|
| 192 | + list($temps, $nav) = chrono_requete($GLOBALS['tableau_des_temps']); |
|
| 193 | 193 | |
| 194 | - return debusquer_navigation($temps, $nav, 'debug-profile'); |
|
| 195 | - } else { |
|
| 196 | - return ''; |
|
| 197 | - } |
|
| 194 | + return debusquer_navigation($temps, $nav, 'debug-profile'); |
|
| 195 | + } else { |
|
| 196 | + return ''; |
|
| 197 | + } |
|
| 198 | 198 | } |
| 199 | 199 | |
| 200 | 200 | /** |
@@ -204,42 +204,42 @@ discard block |
||
| 204 | 204 | * @return string Code HTML |
| 205 | 205 | **/ |
| 206 | 206 | function debusquer_contexte($env) { |
| 207 | - if (is_string($env) and is_array($env_tab = @unserialize($env))) { |
|
| 208 | - $env = $env_tab; |
|
| 209 | - } |
|
| 210 | - |
|
| 211 | - if (!$env) { |
|
| 212 | - return ''; |
|
| 213 | - } |
|
| 214 | - $res = ""; |
|
| 215 | - foreach ($env as $nom => $valeur) { |
|
| 216 | - if (is_array($valeur)) { |
|
| 217 | - $valeur_simple = array(); |
|
| 218 | - foreach ($valeur as $v) { |
|
| 219 | - if (is_array($v)) { |
|
| 220 | - $valeur_simple[] = 'array:' . count($v); |
|
| 221 | - } elseif (is_object($v)) { |
|
| 222 | - $valeur_simple[] = get_class($v); |
|
| 223 | - } elseif (is_string($v)) { |
|
| 224 | - $valeur_simple[] = "'" . $v . "'"; |
|
| 225 | - } else { |
|
| 226 | - $valeur_simple[] = $v; |
|
| 227 | - } |
|
| 228 | - } |
|
| 229 | - $n = count($valeur); |
|
| 230 | - $valeur = (($n > 3) ? 'array:' . $n . ' ' : ''); |
|
| 231 | - $valeur .= '[' . join(', ', $valeur_simple) . ']'; |
|
| 232 | - } elseif (is_object($valeur)) { |
|
| 233 | - $valeur = get_class($valeur); |
|
| 234 | - } elseif (is_string($valeur)) { |
|
| 235 | - $valeur = "'" . $valeur . "'"; |
|
| 236 | - } |
|
| 237 | - $res .= "\n<tr><td><strong>" . nl2br(entites_html($nom)) |
|
| 238 | - . "</strong></td><td>: " . nl2br(entites_html($valeur)) |
|
| 239 | - . "</td></tr>\n"; |
|
| 240 | - } |
|
| 241 | - |
|
| 242 | - return "<div class='spip-env'><fieldset><legend onclick=\"this.parentElement.classList.toggle('expanded');\">#ENV</legend>\n<div><table>$res</table></div></fieldset></div>\n"; |
|
| 207 | + if (is_string($env) and is_array($env_tab = @unserialize($env))) { |
|
| 208 | + $env = $env_tab; |
|
| 209 | + } |
|
| 210 | + |
|
| 211 | + if (!$env) { |
|
| 212 | + return ''; |
|
| 213 | + } |
|
| 214 | + $res = ""; |
|
| 215 | + foreach ($env as $nom => $valeur) { |
|
| 216 | + if (is_array($valeur)) { |
|
| 217 | + $valeur_simple = array(); |
|
| 218 | + foreach ($valeur as $v) { |
|
| 219 | + if (is_array($v)) { |
|
| 220 | + $valeur_simple[] = 'array:' . count($v); |
|
| 221 | + } elseif (is_object($v)) { |
|
| 222 | + $valeur_simple[] = get_class($v); |
|
| 223 | + } elseif (is_string($v)) { |
|
| 224 | + $valeur_simple[] = "'" . $v . "'"; |
|
| 225 | + } else { |
|
| 226 | + $valeur_simple[] = $v; |
|
| 227 | + } |
|
| 228 | + } |
|
| 229 | + $n = count($valeur); |
|
| 230 | + $valeur = (($n > 3) ? 'array:' . $n . ' ' : ''); |
|
| 231 | + $valeur .= '[' . join(', ', $valeur_simple) . ']'; |
|
| 232 | + } elseif (is_object($valeur)) { |
|
| 233 | + $valeur = get_class($valeur); |
|
| 234 | + } elseif (is_string($valeur)) { |
|
| 235 | + $valeur = "'" . $valeur . "'"; |
|
| 236 | + } |
|
| 237 | + $res .= "\n<tr><td><strong>" . nl2br(entites_html($nom)) |
|
| 238 | + . "</strong></td><td>: " . nl2br(entites_html($valeur)) |
|
| 239 | + . "</td></tr>\n"; |
|
| 240 | + } |
|
| 241 | + |
|
| 242 | + return "<div class='spip-env'><fieldset><legend onclick=\"this.parentElement.classList.toggle('expanded');\">#ENV</legend>\n<div><table>$res</table></div></fieldset></div>\n"; |
|
| 243 | 243 | } |
| 244 | 244 | |
| 245 | 245 | // Affichage du tableau des erreurs ou des temps de calcul |
@@ -247,67 +247,67 @@ discard block |
||
| 247 | 247 | |
| 248 | 248 | function debusquer_navigation($tableau, $caption = array(), $id = 'debug-nav') { |
| 249 | 249 | |
| 250 | - if (_request('exec') == 'valider_xml') { |
|
| 251 | - return ''; |
|
| 252 | - } |
|
| 253 | - $GLOBALS['bouton_admin_debug'] = true; |
|
| 254 | - $res = ''; |
|
| 255 | - $href = quote_amp(parametre_url($GLOBALS['REQUEST_URI'], 'var_mode', 'debug')); |
|
| 256 | - foreach ($tableau as $i => $err) { |
|
| 257 | - $boucle = $ligne = $skel = ''; |
|
| 258 | - list($msg, $lieu) = $err; |
|
| 259 | - if (is_object($lieu)) { |
|
| 260 | - $ligne = $lieu->ligne; |
|
| 261 | - $boucle = $lieu->id_boucle ? $lieu->id_boucle : ''; |
|
| 262 | - if (isset($lieu->descr['nom'])) { |
|
| 263 | - $nom_code = $lieu->descr['nom']; |
|
| 264 | - $skel = $lieu->descr['sourcefile']; |
|
| 265 | - $h2 = parametre_url($href, 'var_mode_objet', $nom_code); |
|
| 266 | - $h3 = parametre_url($h2, 'var_mode_affiche', 'squelette') . '#L' . $ligne; |
|
| 267 | - $skel = "<a href='$h3'><b>$skel</b></a>"; |
|
| 268 | - if ($boucle) { |
|
| 269 | - $h3 = parametre_url($h2 . $boucle, 'var_mode_affiche', 'boucle'); |
|
| 270 | - $boucle = "<a href='$h3'><b>$boucle</b></a>"; |
|
| 271 | - } |
|
| 272 | - } |
|
| 273 | - } |
|
| 274 | - |
|
| 275 | - $j = ($i + 1); |
|
| 276 | - $res .= "<tr id='req$j'><td style='text-align: right'>" |
|
| 277 | - . $j |
|
| 278 | - . " </td><td style='text-align: left'>" |
|
| 279 | - . (is_array($msg) ? implode('', $msg) : $msg) |
|
| 280 | - . "</td><td style='text-align: left'>" |
|
| 281 | - . ($skel ? $skel : " / ") |
|
| 282 | - . "</td><td class='spip-debug-arg' style='text-align: left'>" |
|
| 283 | - . ($boucle ? $boucle : " / ") |
|
| 284 | - . "</td><td style='text-align: right'>" |
|
| 285 | - . $ligne |
|
| 286 | - . "</td></tr>\n"; |
|
| 287 | - |
|
| 288 | - } |
|
| 289 | - |
|
| 290 | - return "\n<table id='$id'>" |
|
| 291 | - . "<caption onclick=\"x = document.getElementById('$id'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\">" |
|
| 292 | - . $caption[0] |
|
| 250 | + if (_request('exec') == 'valider_xml') { |
|
| 251 | + return ''; |
|
| 252 | + } |
|
| 253 | + $GLOBALS['bouton_admin_debug'] = true; |
|
| 254 | + $res = ''; |
|
| 255 | + $href = quote_amp(parametre_url($GLOBALS['REQUEST_URI'], 'var_mode', 'debug')); |
|
| 256 | + foreach ($tableau as $i => $err) { |
|
| 257 | + $boucle = $ligne = $skel = ''; |
|
| 258 | + list($msg, $lieu) = $err; |
|
| 259 | + if (is_object($lieu)) { |
|
| 260 | + $ligne = $lieu->ligne; |
|
| 261 | + $boucle = $lieu->id_boucle ? $lieu->id_boucle : ''; |
|
| 262 | + if (isset($lieu->descr['nom'])) { |
|
| 263 | + $nom_code = $lieu->descr['nom']; |
|
| 264 | + $skel = $lieu->descr['sourcefile']; |
|
| 265 | + $h2 = parametre_url($href, 'var_mode_objet', $nom_code); |
|
| 266 | + $h3 = parametre_url($h2, 'var_mode_affiche', 'squelette') . '#L' . $ligne; |
|
| 267 | + $skel = "<a href='$h3'><b>$skel</b></a>"; |
|
| 268 | + if ($boucle) { |
|
| 269 | + $h3 = parametre_url($h2 . $boucle, 'var_mode_affiche', 'boucle'); |
|
| 270 | + $boucle = "<a href='$h3'><b>$boucle</b></a>"; |
|
| 271 | + } |
|
| 272 | + } |
|
| 273 | + } |
|
| 274 | + |
|
| 275 | + $j = ($i + 1); |
|
| 276 | + $res .= "<tr id='req$j'><td style='text-align: right'>" |
|
| 277 | + . $j |
|
| 278 | + . " </td><td style='text-align: left'>" |
|
| 279 | + . (is_array($msg) ? implode('', $msg) : $msg) |
|
| 280 | + . "</td><td style='text-align: left'>" |
|
| 281 | + . ($skel ? $skel : " / ") |
|
| 282 | + . "</td><td class='spip-debug-arg' style='text-align: left'>" |
|
| 283 | + . ($boucle ? $boucle : " / ") |
|
| 284 | + . "</td><td style='text-align: right'>" |
|
| 285 | + . $ligne |
|
| 286 | + . "</td></tr>\n"; |
|
| 287 | + |
|
| 288 | + } |
|
| 289 | + |
|
| 290 | + return "\n<table id='$id'>" |
|
| 291 | + . "<caption onclick=\"x = document.getElementById('$id'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\">" |
|
| 292 | + . $caption[0] |
|
| 293 | 293 | ## aide locale courte a ecrire, avec lien vers une grosse page de documentation |
| 294 | 294 | # aider('erreur_compilation'), |
| 295 | - . "</caption>" |
|
| 296 | - // fausse caption du chrono (mais vraie nav) |
|
| 297 | - . (!empty($caption[1]) ? $caption[1] : '') |
|
| 298 | - . "<tr><th>" |
|
| 299 | - . _T('numero') |
|
| 300 | - . "</th><th>" |
|
| 301 | - . _T('public:message') |
|
| 302 | - . "</th><th>" |
|
| 303 | - . _T('squelette') |
|
| 304 | - . "</th><th>" |
|
| 305 | - . _T('zbug_boucle') |
|
| 306 | - . "</th><th>" |
|
| 307 | - . _T('ligne') |
|
| 308 | - . "</th></tr>" |
|
| 309 | - . $res |
|
| 310 | - . "</table>"; |
|
| 295 | + . "</caption>" |
|
| 296 | + // fausse caption du chrono (mais vraie nav) |
|
| 297 | + . (!empty($caption[1]) ? $caption[1] : '') |
|
| 298 | + . "<tr><th>" |
|
| 299 | + . _T('numero') |
|
| 300 | + . "</th><th>" |
|
| 301 | + . _T('public:message') |
|
| 302 | + . "</th><th>" |
|
| 303 | + . _T('squelette') |
|
| 304 | + . "</th><th>" |
|
| 305 | + . _T('zbug_boucle') |
|
| 306 | + . "</th><th>" |
|
| 307 | + . _T('ligne') |
|
| 308 | + . "</th></tr>" |
|
| 309 | + . $res |
|
| 310 | + . "</table>"; |
|
| 311 | 311 | } |
| 312 | 312 | |
| 313 | 313 | |
@@ -327,125 +327,125 @@ discard block |
||
| 327 | 327 | * ou un tableau si l'erreur est critique |
| 328 | 328 | **/ |
| 329 | 329 | function debusquer_requete($message) { |
| 330 | - list($errno, $msg, $query) = $message; |
|
| 331 | - |
|
| 332 | - // FIXME: ces écritures mélangent divers syntaxe des moteurs SQL |
|
| 333 | - // il serait plus prudent certainement d'avoir une fonction d'analyse par moteur |
|
| 334 | - if (preg_match(',err(no|code):?[[:space:]]*([0-9]+),i', $msg, $regs)) { |
|
| 335 | - $errno = $regs[2]; |
|
| 336 | - } elseif (is_numeric($errno) and ($errno == 1030 or $errno <= 1026) |
|
| 337 | - and preg_match(',[^[:alnum:]]([0-9]+)[^[:alnum:]],', $msg, $regs) |
|
| 338 | - ) { |
|
| 339 | - $errno = $regs[1]; |
|
| 340 | - } |
|
| 341 | - |
|
| 342 | - // Erreur systeme |
|
| 343 | - if (is_numeric($errno) and $errno > 0 and $errno < 200) { |
|
| 344 | - $retour = "<tt><br /><br /><blink>" |
|
| 345 | - . _T('info_erreur_systeme', array('errsys' => $errno)) |
|
| 346 | - . "</blink><br />\n<b>" |
|
| 347 | - . _T('info_erreur_systeme2', |
|
| 348 | - array('script' => generer_url_ecrire('base_repair'))) |
|
| 349 | - . '</b><br />'; |
|
| 350 | - spip_log("Erreur systeme $errno"); |
|
| 351 | - |
|
| 352 | - return array($retour, ''); |
|
| 353 | - } |
|
| 354 | - |
|
| 355 | - // Requete erronee |
|
| 356 | - $err = "<b>" . _T('avis_erreur_mysql') . " $errno</b><br /><tt>\n" |
|
| 357 | - . spip_htmlspecialchars($msg) |
|
| 358 | - . "\n<br /><span style='color: red'><b>" |
|
| 359 | - . spip_htmlspecialchars($query) |
|
| 360 | - . "</b></span></tt><br />"; |
|
| 361 | - |
|
| 362 | - //. aider('erreur_mysql'); |
|
| 363 | - |
|
| 364 | - return $err; |
|
| 330 | + list($errno, $msg, $query) = $message; |
|
| 331 | + |
|
| 332 | + // FIXME: ces écritures mélangent divers syntaxe des moteurs SQL |
|
| 333 | + // il serait plus prudent certainement d'avoir une fonction d'analyse par moteur |
|
| 334 | + if (preg_match(',err(no|code):?[[:space:]]*([0-9]+),i', $msg, $regs)) { |
|
| 335 | + $errno = $regs[2]; |
|
| 336 | + } elseif (is_numeric($errno) and ($errno == 1030 or $errno <= 1026) |
|
| 337 | + and preg_match(',[^[:alnum:]]([0-9]+)[^[:alnum:]],', $msg, $regs) |
|
| 338 | + ) { |
|
| 339 | + $errno = $regs[1]; |
|
| 340 | + } |
|
| 341 | + |
|
| 342 | + // Erreur systeme |
|
| 343 | + if (is_numeric($errno) and $errno > 0 and $errno < 200) { |
|
| 344 | + $retour = "<tt><br /><br /><blink>" |
|
| 345 | + . _T('info_erreur_systeme', array('errsys' => $errno)) |
|
| 346 | + . "</blink><br />\n<b>" |
|
| 347 | + . _T('info_erreur_systeme2', |
|
| 348 | + array('script' => generer_url_ecrire('base_repair'))) |
|
| 349 | + . '</b><br />'; |
|
| 350 | + spip_log("Erreur systeme $errno"); |
|
| 351 | + |
|
| 352 | + return array($retour, ''); |
|
| 353 | + } |
|
| 354 | + |
|
| 355 | + // Requete erronee |
|
| 356 | + $err = "<b>" . _T('avis_erreur_mysql') . " $errno</b><br /><tt>\n" |
|
| 357 | + . spip_htmlspecialchars($msg) |
|
| 358 | + . "\n<br /><span style='color: red'><b>" |
|
| 359 | + . spip_htmlspecialchars($query) |
|
| 360 | + . "</b></span></tt><br />"; |
|
| 361 | + |
|
| 362 | + //. aider('erreur_mysql'); |
|
| 363 | + |
|
| 364 | + return $err; |
|
| 365 | 365 | } |
| 366 | 366 | |
| 367 | 367 | |
| 368 | 368 | // https://code.spip.net/@trouve_boucle_debug |
| 369 | 369 | function trouve_boucle_debug($n, $nom, $debut = 0, $boucle = "") { |
| 370 | 370 | |
| 371 | - $id = $nom . $boucle; |
|
| 372 | - if (is_array($GLOBALS['debug_objets']['sequence'][$id])) { |
|
| 373 | - foreach ($GLOBALS['debug_objets']['sequence'][$id] as $v) { |
|
| 374 | - |
|
| 375 | - if (!preg_match('/^(.*)(<\?.*\?>)(.*)$/s', $v[0], $r)) { |
|
| 376 | - $y = substr_count($v[0], "\n"); |
|
| 377 | - } else { |
|
| 378 | - if ($v[1][0] == '#') // balise dynamique |
|
| 379 | - { |
|
| 380 | - $incl = $GLOBALS['debug_objets']['resultat'][$v[2]]; |
|
| 381 | - } else // inclusion |
|
| 382 | - { |
|
| 383 | - $incl = $GLOBALS['debug_objets']['squelette'][trouve_squelette_inclus($v[0])]; |
|
| 384 | - } |
|
| 385 | - $y = substr_count($incl, "\n") |
|
| 386 | - + substr_count($r[1], "\n") |
|
| 387 | - + substr_count($r[3], "\n"); |
|
| 388 | - } |
|
| 389 | - if ($n <= ($y + $debut)) { |
|
| 390 | - if ($v[1][0] == '?') { |
|
| 391 | - return trouve_boucle_debug($n, $nom, $debut, substr($v[1], 1)); |
|
| 392 | - } elseif ($v[1][0] == '!') { |
|
| 393 | - if ($incl = trouve_squelette_inclus($v[1])) { |
|
| 394 | - return trouve_boucle_debug($n, $incl, $debut); |
|
| 395 | - } |
|
| 396 | - } |
|
| 397 | - |
|
| 398 | - return array($nom, $boucle, $v[2] - 1 + $n - $debut); |
|
| 399 | - } |
|
| 400 | - $debut += $y; |
|
| 401 | - } |
|
| 402 | - } |
|
| 403 | - |
|
| 404 | - return array($nom, $boucle, $n - $debut); |
|
| 371 | + $id = $nom . $boucle; |
|
| 372 | + if (is_array($GLOBALS['debug_objets']['sequence'][$id])) { |
|
| 373 | + foreach ($GLOBALS['debug_objets']['sequence'][$id] as $v) { |
|
| 374 | + |
|
| 375 | + if (!preg_match('/^(.*)(<\?.*\?>)(.*)$/s', $v[0], $r)) { |
|
| 376 | + $y = substr_count($v[0], "\n"); |
|
| 377 | + } else { |
|
| 378 | + if ($v[1][0] == '#') // balise dynamique |
|
| 379 | + { |
|
| 380 | + $incl = $GLOBALS['debug_objets']['resultat'][$v[2]]; |
|
| 381 | + } else // inclusion |
|
| 382 | + { |
|
| 383 | + $incl = $GLOBALS['debug_objets']['squelette'][trouve_squelette_inclus($v[0])]; |
|
| 384 | + } |
|
| 385 | + $y = substr_count($incl, "\n") |
|
| 386 | + + substr_count($r[1], "\n") |
|
| 387 | + + substr_count($r[3], "\n"); |
|
| 388 | + } |
|
| 389 | + if ($n <= ($y + $debut)) { |
|
| 390 | + if ($v[1][0] == '?') { |
|
| 391 | + return trouve_boucle_debug($n, $nom, $debut, substr($v[1], 1)); |
|
| 392 | + } elseif ($v[1][0] == '!') { |
|
| 393 | + if ($incl = trouve_squelette_inclus($v[1])) { |
|
| 394 | + return trouve_boucle_debug($n, $incl, $debut); |
|
| 395 | + } |
|
| 396 | + } |
|
| 397 | + |
|
| 398 | + return array($nom, $boucle, $v[2] - 1 + $n - $debut); |
|
| 399 | + } |
|
| 400 | + $debut += $y; |
|
| 401 | + } |
|
| 402 | + } |
|
| 403 | + |
|
| 404 | + return array($nom, $boucle, $n - $debut); |
|
| 405 | 405 | } |
| 406 | 406 | |
| 407 | 407 | // https://code.spip.net/@trouve_squelette_inclus |
| 408 | 408 | function trouve_squelette_inclus($script) { |
| 409 | 409 | |
| 410 | - preg_match('/include\(.(.*).php3?.\);/', $script, $reg); |
|
| 411 | - // si le script X.php n'est pas ecrire/public.php |
|
| 412 | - // on suppose qu'il prend le squelette X.html (pas sur, mais y a pas mieux) |
|
| 413 | - if ($reg[1] == 'ecrire/public') // si c'est bien ecrire/public on cherche le param 'fond' |
|
| 414 | - { |
|
| 415 | - if (!preg_match("/'fond' => '([^']*)'/", $script, $reg)) // a defaut on cherche le param 'page' |
|
| 416 | - { |
|
| 417 | - if (!preg_match("/'param' => '([^']*)'/", $script, $reg)) { |
|
| 418 | - $reg[1] = "inconnu"; |
|
| 419 | - } |
|
| 420 | - } |
|
| 421 | - } |
|
| 422 | - $incl = ',' . $reg[1] . '[.]\w$,'; |
|
| 423 | - |
|
| 424 | - foreach ($GLOBALS['debug_objets']['sourcefile'] as $k => $v) { |
|
| 425 | - if (preg_match($incl, $v)) { |
|
| 426 | - return $k; |
|
| 427 | - } |
|
| 428 | - } |
|
| 429 | - |
|
| 430 | - return ""; |
|
| 410 | + preg_match('/include\(.(.*).php3?.\);/', $script, $reg); |
|
| 411 | + // si le script X.php n'est pas ecrire/public.php |
|
| 412 | + // on suppose qu'il prend le squelette X.html (pas sur, mais y a pas mieux) |
|
| 413 | + if ($reg[1] == 'ecrire/public') // si c'est bien ecrire/public on cherche le param 'fond' |
|
| 414 | + { |
|
| 415 | + if (!preg_match("/'fond' => '([^']*)'/", $script, $reg)) // a defaut on cherche le param 'page' |
|
| 416 | + { |
|
| 417 | + if (!preg_match("/'param' => '([^']*)'/", $script, $reg)) { |
|
| 418 | + $reg[1] = "inconnu"; |
|
| 419 | + } |
|
| 420 | + } |
|
| 421 | + } |
|
| 422 | + $incl = ',' . $reg[1] . '[.]\w$,'; |
|
| 423 | + |
|
| 424 | + foreach ($GLOBALS['debug_objets']['sourcefile'] as $k => $v) { |
|
| 425 | + if (preg_match($incl, $v)) { |
|
| 426 | + return $k; |
|
| 427 | + } |
|
| 428 | + } |
|
| 429 | + |
|
| 430 | + return ""; |
|
| 431 | 431 | } |
| 432 | 432 | |
| 433 | 433 | // https://code.spip.net/@reference_boucle_debug |
| 434 | 434 | function reference_boucle_debug($n, $nom, $self) { |
| 435 | - list($skel, $boucle, $ligne) = trouve_boucle_debug($n, $nom); |
|
| 436 | - |
|
| 437 | - if (!$boucle) { |
|
| 438 | - return !$ligne ? "" : |
|
| 439 | - (" (" . |
|
| 440 | - (($nom != $skel) ? _T('squelette_inclus_ligne') : |
|
| 441 | - _T('squelette_ligne')) . |
|
| 442 | - " <a href='$self&var_mode_objet=$skel&var_mode_affiche=squelette&var_mode_ligne=$ligne#L$ligne'>$ligne</a>)"); |
|
| 443 | - } else { |
|
| 444 | - $self .= "&var_mode_objet=$skel$boucle&var_mode_affiche=boucle"; |
|
| 445 | - |
|
| 446 | - return !$ligne ? " (boucle\n<a href='$self#$skel$boucle'>$boucle</a>)" : |
|
| 447 | - " (boucle $boucle ligne\n<a href='$self&var_mode_ligne=$ligne#L$ligne'>$ligne</a>)"; |
|
| 448 | - } |
|
| 435 | + list($skel, $boucle, $ligne) = trouve_boucle_debug($n, $nom); |
|
| 436 | + |
|
| 437 | + if (!$boucle) { |
|
| 438 | + return !$ligne ? "" : |
|
| 439 | + (" (" . |
|
| 440 | + (($nom != $skel) ? _T('squelette_inclus_ligne') : |
|
| 441 | + _T('squelette_ligne')) . |
|
| 442 | + " <a href='$self&var_mode_objet=$skel&var_mode_affiche=squelette&var_mode_ligne=$ligne#L$ligne'>$ligne</a>)"); |
|
| 443 | + } else { |
|
| 444 | + $self .= "&var_mode_objet=$skel$boucle&var_mode_affiche=boucle"; |
|
| 445 | + |
|
| 446 | + return !$ligne ? " (boucle\n<a href='$self#$skel$boucle'>$boucle</a>)" : |
|
| 447 | + " (boucle $boucle ligne\n<a href='$self&var_mode_ligne=$ligne#L$ligne'>$ligne</a>)"; |
|
| 448 | + } |
|
| 449 | 449 | } |
| 450 | 450 | |
| 451 | 451 | // affiche un texte avec numero de ligne et ancre. |
@@ -453,395 +453,395 @@ discard block |
||
| 453 | 453 | // https://code.spip.net/@ancre_texte |
| 454 | 454 | function ancre_texte($texte, $fautifs = array(), $nocpt = false) { |
| 455 | 455 | |
| 456 | - $var_mode_ligne = _request('var_mode_ligne'); |
|
| 457 | - if ($var_mode_ligne) { |
|
| 458 | - $fautifs[] = array($var_mode_ligne); |
|
| 459 | - } |
|
| 460 | - $res = ''; |
|
| 461 | - |
|
| 462 | - $s = highlight_string($texte, true); |
|
| 463 | - if (substr($s, 0, 6) == '<code>') { |
|
| 464 | - $s = substr($s, 6); |
|
| 465 | - $res = '<code>'; |
|
| 466 | - } |
|
| 467 | - |
|
| 468 | - $s = preg_replace(',<(\w[^<>]*)>([^<]*)<br />([^<]*)</\1>,', |
|
| 469 | - '<\1>\2</\1><br />' . "\n" . '<\1>\3</\1>', |
|
| 470 | - $s); |
|
| 471 | - |
|
| 472 | - |
|
| 473 | - $tableau = explode("<br />", $s); |
|
| 474 | - |
|
| 475 | - $format = "<span style='float:left;display:block;width:50px;height:1px'><a id='L%d' style='background-color: white; visibility: " . ($nocpt ? 'hidden' : 'visible') . ";%s' href='#T%s' title=\"%s\">%0" . strval(@strlen(count($tableau))) . "d</a></span> %s<br />\n"; |
|
| 476 | - |
|
| 477 | - $format10 = str_replace('white', 'lightgrey', $format); |
|
| 478 | - $formaterr = "color: red;"; |
|
| 479 | - $i = 1; |
|
| 480 | - $flignes = array(); |
|
| 481 | - $loc = array(0, 0); |
|
| 482 | - foreach ($fautifs as $lc) { |
|
| 483 | - if (is_array($lc)) { |
|
| 484 | - $l = array_shift($lc); |
|
| 485 | - $flignes[$l] = $lc; |
|
| 486 | - } else { |
|
| 487 | - $flignes[$lc] = $loc; |
|
| 488 | - } |
|
| 489 | - } |
|
| 490 | - |
|
| 491 | - $ancre = md5($texte); |
|
| 492 | - foreach ($tableau as $ligne) { |
|
| 493 | - if (isset($flignes[$i])) { |
|
| 494 | - $ligne = str_replace(' ', ' ', $ligne); |
|
| 495 | - $indexmesg = $flignes[$i][1]; |
|
| 496 | - $err = textebrut($flignes[$i][2]); |
|
| 497 | - // tentative de pointer sur la colonne fautive; |
|
| 498 | - // marche pas car highlight_string rajoute des entites. A revoir. |
|
| 499 | - // $m = $flignes[$i][0]; |
|
| 500 | - // $ligne = substr($ligne, 0, $m-1) . |
|
| 501 | - // sprintf($formaterr, substr($ligne,$m)); |
|
| 502 | - $bg = $formaterr; |
|
| 503 | - } else { |
|
| 504 | - $indexmesg = $ancre; |
|
| 505 | - $err = $bg = ''; |
|
| 506 | - } |
|
| 507 | - $res .= sprintf((($i % 10) ? $format : $format10), $i, $bg, $indexmesg, $err, $i, $ligne); |
|
| 508 | - $i++; |
|
| 509 | - } |
|
| 510 | - |
|
| 511 | - return "<div id='T$ancre'>" |
|
| 512 | - . '<div onclick="' |
|
| 513 | - . "jQuery(this).parent().find('a').toggle();" |
|
| 514 | - . '" title="' |
|
| 515 | - . _T('masquer_colonne') |
|
| 516 | - . '" style="cursor: pointer;">' |
|
| 517 | - . ($nocpt ? '' : _T('info_numero_abbreviation')) |
|
| 518 | - . "</div> |
|
| 456 | + $var_mode_ligne = _request('var_mode_ligne'); |
|
| 457 | + if ($var_mode_ligne) { |
|
| 458 | + $fautifs[] = array($var_mode_ligne); |
|
| 459 | + } |
|
| 460 | + $res = ''; |
|
| 461 | + |
|
| 462 | + $s = highlight_string($texte, true); |
|
| 463 | + if (substr($s, 0, 6) == '<code>') { |
|
| 464 | + $s = substr($s, 6); |
|
| 465 | + $res = '<code>'; |
|
| 466 | + } |
|
| 467 | + |
|
| 468 | + $s = preg_replace(',<(\w[^<>]*)>([^<]*)<br />([^<]*)</\1>,', |
|
| 469 | + '<\1>\2</\1><br />' . "\n" . '<\1>\3</\1>', |
|
| 470 | + $s); |
|
| 471 | + |
|
| 472 | + |
|
| 473 | + $tableau = explode("<br />", $s); |
|
| 474 | + |
|
| 475 | + $format = "<span style='float:left;display:block;width:50px;height:1px'><a id='L%d' style='background-color: white; visibility: " . ($nocpt ? 'hidden' : 'visible') . ";%s' href='#T%s' title=\"%s\">%0" . strval(@strlen(count($tableau))) . "d</a></span> %s<br />\n"; |
|
| 476 | + |
|
| 477 | + $format10 = str_replace('white', 'lightgrey', $format); |
|
| 478 | + $formaterr = "color: red;"; |
|
| 479 | + $i = 1; |
|
| 480 | + $flignes = array(); |
|
| 481 | + $loc = array(0, 0); |
|
| 482 | + foreach ($fautifs as $lc) { |
|
| 483 | + if (is_array($lc)) { |
|
| 484 | + $l = array_shift($lc); |
|
| 485 | + $flignes[$l] = $lc; |
|
| 486 | + } else { |
|
| 487 | + $flignes[$lc] = $loc; |
|
| 488 | + } |
|
| 489 | + } |
|
| 490 | + |
|
| 491 | + $ancre = md5($texte); |
|
| 492 | + foreach ($tableau as $ligne) { |
|
| 493 | + if (isset($flignes[$i])) { |
|
| 494 | + $ligne = str_replace(' ', ' ', $ligne); |
|
| 495 | + $indexmesg = $flignes[$i][1]; |
|
| 496 | + $err = textebrut($flignes[$i][2]); |
|
| 497 | + // tentative de pointer sur la colonne fautive; |
|
| 498 | + // marche pas car highlight_string rajoute des entites. A revoir. |
|
| 499 | + // $m = $flignes[$i][0]; |
|
| 500 | + // $ligne = substr($ligne, 0, $m-1) . |
|
| 501 | + // sprintf($formaterr, substr($ligne,$m)); |
|
| 502 | + $bg = $formaterr; |
|
| 503 | + } else { |
|
| 504 | + $indexmesg = $ancre; |
|
| 505 | + $err = $bg = ''; |
|
| 506 | + } |
|
| 507 | + $res .= sprintf((($i % 10) ? $format : $format10), $i, $bg, $indexmesg, $err, $i, $ligne); |
|
| 508 | + $i++; |
|
| 509 | + } |
|
| 510 | + |
|
| 511 | + return "<div id='T$ancre'>" |
|
| 512 | + . '<div onclick="' |
|
| 513 | + . "jQuery(this).parent().find('a').toggle();" |
|
| 514 | + . '" title="' |
|
| 515 | + . _T('masquer_colonne') |
|
| 516 | + . '" style="cursor: pointer;">' |
|
| 517 | + . ($nocpt ? '' : _T('info_numero_abbreviation')) |
|
| 518 | + . "</div> |
|
| 519 | 519 | " . $res . "</div>\n"; |
| 520 | 520 | } |
| 521 | 521 | |
| 522 | 522 | // l'environnement graphique du debuggueur |
| 523 | 523 | |
| 524 | 524 | function debusquer_squelette($fonc, $mode, $self) { |
| 525 | - $texte = ''; |
|
| 526 | - |
|
| 527 | - if ($mode !== 'validation') { |
|
| 528 | - if (isset($GLOBALS['debug_objets']['sourcefile']) and $GLOBALS['debug_objets']['sourcefile']) { |
|
| 529 | - $res = "<div id='spip-boucles'>\n" |
|
| 530 | - . debusquer_navigation_squelettes($self) |
|
| 531 | - . "</div>"; |
|
| 532 | - } else { |
|
| 533 | - $res = ''; |
|
| 534 | - } |
|
| 535 | - if ($fonc) { |
|
| 536 | - $id = " id='$fonc'"; |
|
| 537 | - if (!empty($GLOBALS['debug_objets'][$mode][$fonc])) { |
|
| 538 | - list($legend, $texte, $res2) = debusquer_source($fonc, $mode); |
|
| 539 | - $texte .= $res2; |
|
| 540 | - } elseif (!empty($GLOBALS['debug_objets'][$mode][$fonc . 'tout'])) { |
|
| 541 | - $legend = _T('zbug_' . $mode); |
|
| 542 | - $texte = $GLOBALS['debug_objets'][$mode][$fonc . 'tout']; |
|
| 543 | - $texte = ancre_texte($texte, array('', '')); |
|
| 544 | - } |
|
| 545 | - } else { |
|
| 546 | - if (strlen(trim($res))) { |
|
| 547 | - return "<img src='" . chemin_image('debug-xx.svg') . "' alt='afficher-masquer le debug' id='spip-debug-toggle' onclick=\"var x = document.getElementById('spip-debug'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\" /><div id='spip-debug'>$res</div>"; |
|
| 548 | - } else { |
|
| 549 | - // cas de l'appel sur erreur: montre la page |
|
| 550 | - return isset($GLOBALS['debug_objets']['resultat']['tout']) |
|
| 551 | - ? $GLOBALS['debug_objets']['resultat']['tout'] |
|
| 552 | - : ''; |
|
| 553 | - } |
|
| 554 | - } |
|
| 555 | - } else { |
|
| 556 | - $valider = charger_fonction('valider', 'xml'); |
|
| 557 | - $val = $valider($GLOBALS['debug_objets']['validation'][$fonc . 'tout']); |
|
| 558 | - // Si erreur, signaler leur nombre dans le formulaire admin |
|
| 559 | - $GLOBALS['debug_objets']['validation'] = $val->err ? count($val->err) : ''; |
|
| 560 | - list($texte, $err) = emboite_texte($val, $fonc, $self); |
|
| 561 | - if ($err === false) { |
|
| 562 | - $err = _T('impossible'); |
|
| 563 | - } elseif ($err === true) { |
|
| 564 | - $err = _T('correcte'); |
|
| 565 | - } else { |
|
| 566 | - $err = ": $err"; |
|
| 567 | - } |
|
| 568 | - $legend = _T('validation') . ' ' . $err; |
|
| 569 | - $res = $id = ''; |
|
| 570 | - } |
|
| 571 | - |
|
| 572 | - return !trim($texte) ? '' : ( |
|
| 573 | - "<img src='" . chemin_image('debug-xx.svg') . "' alt='afficher-masquer le debug' id='spip-debug-toggle' onclick=\"var x = document.getElementById('spip-debug'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\" /><div id='spip-debug'>$res" |
|
| 574 | - . "<div id='debug_boucle'><fieldset$id><legend>" |
|
| 575 | - . "<a href='" . $self . "#f_" . substr($fonc, 0, 37) . "'> ↑ " |
|
| 576 | - . ($legend ? $legend : $mode) |
|
| 577 | - . "</a></legend>" |
|
| 578 | - . $texte |
|
| 579 | - . "</fieldset></div>" |
|
| 580 | - . "</div>"); |
|
| 525 | + $texte = ''; |
|
| 526 | + |
|
| 527 | + if ($mode !== 'validation') { |
|
| 528 | + if (isset($GLOBALS['debug_objets']['sourcefile']) and $GLOBALS['debug_objets']['sourcefile']) { |
|
| 529 | + $res = "<div id='spip-boucles'>\n" |
|
| 530 | + . debusquer_navigation_squelettes($self) |
|
| 531 | + . "</div>"; |
|
| 532 | + } else { |
|
| 533 | + $res = ''; |
|
| 534 | + } |
|
| 535 | + if ($fonc) { |
|
| 536 | + $id = " id='$fonc'"; |
|
| 537 | + if (!empty($GLOBALS['debug_objets'][$mode][$fonc])) { |
|
| 538 | + list($legend, $texte, $res2) = debusquer_source($fonc, $mode); |
|
| 539 | + $texte .= $res2; |
|
| 540 | + } elseif (!empty($GLOBALS['debug_objets'][$mode][$fonc . 'tout'])) { |
|
| 541 | + $legend = _T('zbug_' . $mode); |
|
| 542 | + $texte = $GLOBALS['debug_objets'][$mode][$fonc . 'tout']; |
|
| 543 | + $texte = ancre_texte($texte, array('', '')); |
|
| 544 | + } |
|
| 545 | + } else { |
|
| 546 | + if (strlen(trim($res))) { |
|
| 547 | + return "<img src='" . chemin_image('debug-xx.svg') . "' alt='afficher-masquer le debug' id='spip-debug-toggle' onclick=\"var x = document.getElementById('spip-debug'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\" /><div id='spip-debug'>$res</div>"; |
|
| 548 | + } else { |
|
| 549 | + // cas de l'appel sur erreur: montre la page |
|
| 550 | + return isset($GLOBALS['debug_objets']['resultat']['tout']) |
|
| 551 | + ? $GLOBALS['debug_objets']['resultat']['tout'] |
|
| 552 | + : ''; |
|
| 553 | + } |
|
| 554 | + } |
|
| 555 | + } else { |
|
| 556 | + $valider = charger_fonction('valider', 'xml'); |
|
| 557 | + $val = $valider($GLOBALS['debug_objets']['validation'][$fonc . 'tout']); |
|
| 558 | + // Si erreur, signaler leur nombre dans le formulaire admin |
|
| 559 | + $GLOBALS['debug_objets']['validation'] = $val->err ? count($val->err) : ''; |
|
| 560 | + list($texte, $err) = emboite_texte($val, $fonc, $self); |
|
| 561 | + if ($err === false) { |
|
| 562 | + $err = _T('impossible'); |
|
| 563 | + } elseif ($err === true) { |
|
| 564 | + $err = _T('correcte'); |
|
| 565 | + } else { |
|
| 566 | + $err = ": $err"; |
|
| 567 | + } |
|
| 568 | + $legend = _T('validation') . ' ' . $err; |
|
| 569 | + $res = $id = ''; |
|
| 570 | + } |
|
| 571 | + |
|
| 572 | + return !trim($texte) ? '' : ( |
|
| 573 | + "<img src='" . chemin_image('debug-xx.svg') . "' alt='afficher-masquer le debug' id='spip-debug-toggle' onclick=\"var x = document.getElementById('spip-debug'); (x.style.display == '' ? x.style.display = 'none' : x.style.display = '');\" /><div id='spip-debug'>$res" |
|
| 574 | + . "<div id='debug_boucle'><fieldset$id><legend>" |
|
| 575 | + . "<a href='" . $self . "#f_" . substr($fonc, 0, 37) . "'> ↑ " |
|
| 576 | + . ($legend ? $legend : $mode) |
|
| 577 | + . "</a></legend>" |
|
| 578 | + . $texte |
|
| 579 | + . "</fieldset></div>" |
|
| 580 | + . "</div>"); |
|
| 581 | 581 | } |
| 582 | 582 | |
| 583 | 583 | |
| 584 | 584 | // https://code.spip.net/@emboite_texte |
| 585 | 585 | function emboite_texte($res, $fonc = '', $self = '') { |
| 586 | - $errs = $res->err; |
|
| 587 | - $texte = $res->entete . ($errs ? '' : $res->page); |
|
| 588 | - |
|
| 589 | - if (!$texte and !$errs) { |
|
| 590 | - return array(ancre_texte('', array('', '')), false); |
|
| 591 | - } |
|
| 592 | - if (!$errs) { |
|
| 593 | - return array(ancre_texte($texte, array('', '')), true); |
|
| 594 | - } |
|
| 595 | - |
|
| 596 | - if (!isset($GLOBALS['debug_objets'])) { |
|
| 597 | - |
|
| 598 | - $colors = array('#e0e0f0', '#f8f8ff'); |
|
| 599 | - $encore = count_occ($errs); |
|
| 600 | - $encore2 = array(); |
|
| 601 | - $fautifs = array(); |
|
| 602 | - |
|
| 603 | - $err = '<tr><th>' |
|
| 604 | - . _T('numero') |
|
| 605 | - . "</th><th>" |
|
| 606 | - . _T('occurence') |
|
| 607 | - . "</th><th>" |
|
| 608 | - . _T('ligne') |
|
| 609 | - . "</th><th>" |
|
| 610 | - . _T('colonne') |
|
| 611 | - . "</th><th>" |
|
| 612 | - . _T('erreur') |
|
| 613 | - . "</th></tr>"; |
|
| 614 | - |
|
| 615 | - $i = 0; |
|
| 616 | - $style = "style='text-align: right; padding-right: 5px'"; |
|
| 617 | - foreach ($errs as $r) { |
|
| 618 | - $i++; |
|
| 619 | - list($msg, $ligne, $col) = $r; |
|
| 620 | - #spip_log("$r = list($msg, $ligne, $col"); |
|
| 621 | - if (isset($encore2[$msg])) { |
|
| 622 | - $ref = ++$encore2[$msg]; |
|
| 623 | - } else { |
|
| 624 | - $encore2[$msg] = $ref = 1; |
|
| 625 | - } |
|
| 626 | - $err .= "<tr style='background-color: " |
|
| 627 | - . $colors[$i % 2] |
|
| 628 | - . "'><td $style><a href='#debut_err'>" |
|
| 629 | - . $i |
|
| 630 | - . "</a></td><td $style>" |
|
| 631 | - . "$ref/$encore[$msg]</td>" |
|
| 632 | - . "<td $style><a href='#L" |
|
| 633 | - . $ligne |
|
| 634 | - . "' id='T$i'>" |
|
| 635 | - . $ligne |
|
| 636 | - . "</a></td><td $style>" |
|
| 637 | - . $col |
|
| 638 | - . "</td><td>$msg</td></tr>\n"; |
|
| 639 | - $fautifs[] = array($ligne, $col, $i, $msg); |
|
| 640 | - } |
|
| 641 | - $err = "<h2 style='text-align: center'>" |
|
| 642 | - . $i |
|
| 643 | - . "<a href='#fin_err'>" |
|
| 644 | - . " " . _T('erreur_texte') |
|
| 645 | - . "</a></h2><table id='debut_err' style='width: 100%'>" |
|
| 646 | - . $err |
|
| 647 | - . " </table><a id='fin_err'></a>"; |
|
| 648 | - |
|
| 649 | - return array(ancre_texte($texte, $fautifs), $err); |
|
| 650 | - } else { |
|
| 651 | - list($msg, $fermant, $ouvrant) = $errs[0]; |
|
| 652 | - $rf = reference_boucle_debug($fermant, $fonc, $self); |
|
| 653 | - $ro = reference_boucle_debug($ouvrant, $fonc, $self); |
|
| 654 | - $err = $msg . |
|
| 655 | - "<a href='#L" . $fermant . "'>$fermant</a>$rf<br />" . |
|
| 656 | - "<a href='#L" . $ouvrant . "'>$ouvrant</a>$ro"; |
|
| 657 | - |
|
| 658 | - return array(ancre_texte($texte, array(array($ouvrant), array($fermant))), $err); |
|
| 659 | - } |
|
| 586 | + $errs = $res->err; |
|
| 587 | + $texte = $res->entete . ($errs ? '' : $res->page); |
|
| 588 | + |
|
| 589 | + if (!$texte and !$errs) { |
|
| 590 | + return array(ancre_texte('', array('', '')), false); |
|
| 591 | + } |
|
| 592 | + if (!$errs) { |
|
| 593 | + return array(ancre_texte($texte, array('', '')), true); |
|
| 594 | + } |
|
| 595 | + |
|
| 596 | + if (!isset($GLOBALS['debug_objets'])) { |
|
| 597 | + |
|
| 598 | + $colors = array('#e0e0f0', '#f8f8ff'); |
|
| 599 | + $encore = count_occ($errs); |
|
| 600 | + $encore2 = array(); |
|
| 601 | + $fautifs = array(); |
|
| 602 | + |
|
| 603 | + $err = '<tr><th>' |
|
| 604 | + . _T('numero') |
|
| 605 | + . "</th><th>" |
|
| 606 | + . _T('occurence') |
|
| 607 | + . "</th><th>" |
|
| 608 | + . _T('ligne') |
|
| 609 | + . "</th><th>" |
|
| 610 | + . _T('colonne') |
|
| 611 | + . "</th><th>" |
|
| 612 | + . _T('erreur') |
|
| 613 | + . "</th></tr>"; |
|
| 614 | + |
|
| 615 | + $i = 0; |
|
| 616 | + $style = "style='text-align: right; padding-right: 5px'"; |
|
| 617 | + foreach ($errs as $r) { |
|
| 618 | + $i++; |
|
| 619 | + list($msg, $ligne, $col) = $r; |
|
| 620 | + #spip_log("$r = list($msg, $ligne, $col"); |
|
| 621 | + if (isset($encore2[$msg])) { |
|
| 622 | + $ref = ++$encore2[$msg]; |
|
| 623 | + } else { |
|
| 624 | + $encore2[$msg] = $ref = 1; |
|
| 625 | + } |
|
| 626 | + $err .= "<tr style='background-color: " |
|
| 627 | + . $colors[$i % 2] |
|
| 628 | + . "'><td $style><a href='#debut_err'>" |
|
| 629 | + . $i |
|
| 630 | + . "</a></td><td $style>" |
|
| 631 | + . "$ref/$encore[$msg]</td>" |
|
| 632 | + . "<td $style><a href='#L" |
|
| 633 | + . $ligne |
|
| 634 | + . "' id='T$i'>" |
|
| 635 | + . $ligne |
|
| 636 | + . "</a></td><td $style>" |
|
| 637 | + . $col |
|
| 638 | + . "</td><td>$msg</td></tr>\n"; |
|
| 639 | + $fautifs[] = array($ligne, $col, $i, $msg); |
|
| 640 | + } |
|
| 641 | + $err = "<h2 style='text-align: center'>" |
|
| 642 | + . $i |
|
| 643 | + . "<a href='#fin_err'>" |
|
| 644 | + . " " . _T('erreur_texte') |
|
| 645 | + . "</a></h2><table id='debut_err' style='width: 100%'>" |
|
| 646 | + . $err |
|
| 647 | + . " </table><a id='fin_err'></a>"; |
|
| 648 | + |
|
| 649 | + return array(ancre_texte($texte, $fautifs), $err); |
|
| 650 | + } else { |
|
| 651 | + list($msg, $fermant, $ouvrant) = $errs[0]; |
|
| 652 | + $rf = reference_boucle_debug($fermant, $fonc, $self); |
|
| 653 | + $ro = reference_boucle_debug($ouvrant, $fonc, $self); |
|
| 654 | + $err = $msg . |
|
| 655 | + "<a href='#L" . $fermant . "'>$fermant</a>$rf<br />" . |
|
| 656 | + "<a href='#L" . $ouvrant . "'>$ouvrant</a>$ro"; |
|
| 657 | + |
|
| 658 | + return array(ancre_texte($texte, array(array($ouvrant), array($fermant))), $err); |
|
| 659 | + } |
|
| 660 | 660 | } |
| 661 | 661 | |
| 662 | 662 | // https://code.spip.net/@count_occ |
| 663 | 663 | function count_occ($regs) { |
| 664 | - $encore = array(); |
|
| 665 | - foreach ($regs as $r) { |
|
| 666 | - if (isset($encore[$r[0]])) { |
|
| 667 | - $encore[$r[0]]++; |
|
| 668 | - } else { |
|
| 669 | - $encore[$r[0]] = 1; |
|
| 670 | - } |
|
| 671 | - } |
|
| 672 | - |
|
| 673 | - return $encore; |
|
| 664 | + $encore = array(); |
|
| 665 | + foreach ($regs as $r) { |
|
| 666 | + if (isset($encore[$r[0]])) { |
|
| 667 | + $encore[$r[0]]++; |
|
| 668 | + } else { |
|
| 669 | + $encore[$r[0]] = 1; |
|
| 670 | + } |
|
| 671 | + } |
|
| 672 | + |
|
| 673 | + return $encore; |
|
| 674 | 674 | } |
| 675 | 675 | |
| 676 | 676 | function debusquer_navigation_squelettes($self) { |
| 677 | 677 | |
| 678 | - $res = ''; |
|
| 679 | - $boucles = !empty($GLOBALS['debug_objets']['boucle']) ? $GLOBALS['debug_objets']['boucle'] : ''; |
|
| 680 | - $contexte = $GLOBALS['debug_objets']['contexte']; |
|
| 681 | - $t_skel = _T('squelette'); |
|
| 682 | - foreach ($GLOBALS['debug_objets']['sourcefile'] as $nom => $sourcefile) { |
|
| 683 | - $self2 = parametre_url($self, 'var_mode_objet', $nom); |
|
| 684 | - $nav = !$boucles ? '' : debusquer_navigation_boucles($boucles, $nom, $self, $sourcefile); |
|
| 685 | - $temps = !isset($GLOBALS['debug_objets']['profile'][$sourcefile]) ? '' : _T('zbug_profile', |
|
| 686 | - array('time' => $GLOBALS['debug_objets']['profile'][$sourcefile])); |
|
| 687 | - |
|
| 688 | - $res .= "<fieldset id='f_" . $nom . "'><legend>" |
|
| 689 | - . $t_skel |
|
| 690 | - . ' ' |
|
| 691 | - . $sourcefile |
|
| 692 | - . " :\n<a href='$self2&var_mode_affiche=squelette#f_$nom'>" |
|
| 693 | - . $t_skel |
|
| 694 | - . "</a>\n<a href='$self2&var_mode_affiche=resultat#f_$nom'>" |
|
| 695 | - . _T('zbug_resultat') |
|
| 696 | - . "</a>\n<a href='$self2&var_mode_affiche=code#f_$nom'>" |
|
| 697 | - . _T('zbug_code') |
|
| 698 | - . "</a>\n<a href='" |
|
| 699 | - . str_replace('var_mode=debug', 'var_profile=1&var_mode=recalcul', $self) |
|
| 700 | - . "'>" |
|
| 701 | - . _T('zbug_calcul') |
|
| 702 | - . "</a></legend>" |
|
| 703 | - . (!$temps ? '' : ("\n<span style='display:block;float:" . $GLOBALS['spip_lang_right'] . "'>$temps</span><br />")) |
|
| 704 | - . debusquer_contexte($contexte[$sourcefile]) |
|
| 705 | - . (!$nav ? '' : ("<table width='100%'>\n$nav</table>\n")) |
|
| 706 | - . "</fieldset>\n"; |
|
| 707 | - } |
|
| 708 | - |
|
| 709 | - return $res; |
|
| 678 | + $res = ''; |
|
| 679 | + $boucles = !empty($GLOBALS['debug_objets']['boucle']) ? $GLOBALS['debug_objets']['boucle'] : ''; |
|
| 680 | + $contexte = $GLOBALS['debug_objets']['contexte']; |
|
| 681 | + $t_skel = _T('squelette'); |
|
| 682 | + foreach ($GLOBALS['debug_objets']['sourcefile'] as $nom => $sourcefile) { |
|
| 683 | + $self2 = parametre_url($self, 'var_mode_objet', $nom); |
|
| 684 | + $nav = !$boucles ? '' : debusquer_navigation_boucles($boucles, $nom, $self, $sourcefile); |
|
| 685 | + $temps = !isset($GLOBALS['debug_objets']['profile'][$sourcefile]) ? '' : _T('zbug_profile', |
|
| 686 | + array('time' => $GLOBALS['debug_objets']['profile'][$sourcefile])); |
|
| 687 | + |
|
| 688 | + $res .= "<fieldset id='f_" . $nom . "'><legend>" |
|
| 689 | + . $t_skel |
|
| 690 | + . ' ' |
|
| 691 | + . $sourcefile |
|
| 692 | + . " :\n<a href='$self2&var_mode_affiche=squelette#f_$nom'>" |
|
| 693 | + . $t_skel |
|
| 694 | + . "</a>\n<a href='$self2&var_mode_affiche=resultat#f_$nom'>" |
|
| 695 | + . _T('zbug_resultat') |
|
| 696 | + . "</a>\n<a href='$self2&var_mode_affiche=code#f_$nom'>" |
|
| 697 | + . _T('zbug_code') |
|
| 698 | + . "</a>\n<a href='" |
|
| 699 | + . str_replace('var_mode=debug', 'var_profile=1&var_mode=recalcul', $self) |
|
| 700 | + . "'>" |
|
| 701 | + . _T('zbug_calcul') |
|
| 702 | + . "</a></legend>" |
|
| 703 | + . (!$temps ? '' : ("\n<span style='display:block;float:" . $GLOBALS['spip_lang_right'] . "'>$temps</span><br />")) |
|
| 704 | + . debusquer_contexte($contexte[$sourcefile]) |
|
| 705 | + . (!$nav ? '' : ("<table width='100%'>\n$nav</table>\n")) |
|
| 706 | + . "</fieldset>\n"; |
|
| 707 | + } |
|
| 708 | + |
|
| 709 | + return $res; |
|
| 710 | 710 | } |
| 711 | 711 | |
| 712 | 712 | function debusquer_navigation_boucles($boucles, $nom_skel, $self, $nom_source) { |
| 713 | - $i = 0; |
|
| 714 | - $res = ''; |
|
| 715 | - $var_mode_objet = _request('var_mode_objet'); |
|
| 716 | - $gram = preg_match('/[.](\w+)$/', $nom_source, $r) ? $r[1] : ''; |
|
| 717 | - |
|
| 718 | - foreach ($boucles as $objet => $boucle) { |
|
| 719 | - if (substr($objet, 0, strlen($nom_skel)) == $nom_skel) { |
|
| 720 | - $i++; |
|
| 721 | - $nom = $boucle->id_boucle; |
|
| 722 | - $req = $boucle->type_requete; |
|
| 723 | - $crit = public_decompiler($boucle, $gram, 0, 'criteres'); |
|
| 724 | - $self2 = $self . "&var_mode_objet=" . $objet; |
|
| 725 | - |
|
| 726 | - $res .= "\n<tr style='background-color: " . |
|
| 727 | - ($i % 2 ? '#e0e0f0' : '#f8f8ff') . |
|
| 728 | - "'><td align='right'>$i</td><td>\n" . |
|
| 729 | - "<a class='debug_link_boucle' href='" . |
|
| 730 | - $self2 . |
|
| 731 | - "&var_mode_affiche=boucle#f_$nom_skel'>" . |
|
| 732 | - _T('zbug_boucle') . |
|
| 733 | - "</a></td><td>\n<a class='debug_link_boucle' href='" . |
|
| 734 | - $self2 . |
|
| 735 | - "&var_mode_affiche=resultat#f_$nom_skel'>" . |
|
| 736 | - _T('zbug_resultat') . |
|
| 737 | - "</a></td><td>\n<a class='debug_link_resultat' href='" . |
|
| 738 | - $self2 . |
|
| 739 | - "&var_mode_affiche=code#f_$nom_skel'>" . |
|
| 740 | - _T('zbug_code') . |
|
| 741 | - "</a></td><td>\n<a class='debug_link_resultat' href='" . |
|
| 742 | - str_replace('var_mode=', 'var_profile=', $self2) . |
|
| 743 | - "'>" . |
|
| 744 | - _T('zbug_calcul') . |
|
| 745 | - "</a></td><td>\n" . |
|
| 746 | - (($var_mode_objet == $objet) ? "<b>$nom</b>" : $nom) . |
|
| 747 | - "</td><td>\n" . |
|
| 748 | - $req . |
|
| 749 | - "</td><td>\n" . |
|
| 750 | - spip_htmlspecialchars($crit) . |
|
| 751 | - "</td></tr>"; |
|
| 752 | - } |
|
| 753 | - } |
|
| 754 | - |
|
| 755 | - return $res; |
|
| 713 | + $i = 0; |
|
| 714 | + $res = ''; |
|
| 715 | + $var_mode_objet = _request('var_mode_objet'); |
|
| 716 | + $gram = preg_match('/[.](\w+)$/', $nom_source, $r) ? $r[1] : ''; |
|
| 717 | + |
|
| 718 | + foreach ($boucles as $objet => $boucle) { |
|
| 719 | + if (substr($objet, 0, strlen($nom_skel)) == $nom_skel) { |
|
| 720 | + $i++; |
|
| 721 | + $nom = $boucle->id_boucle; |
|
| 722 | + $req = $boucle->type_requete; |
|
| 723 | + $crit = public_decompiler($boucle, $gram, 0, 'criteres'); |
|
| 724 | + $self2 = $self . "&var_mode_objet=" . $objet; |
|
| 725 | + |
|
| 726 | + $res .= "\n<tr style='background-color: " . |
|
| 727 | + ($i % 2 ? '#e0e0f0' : '#f8f8ff') . |
|
| 728 | + "'><td align='right'>$i</td><td>\n" . |
|
| 729 | + "<a class='debug_link_boucle' href='" . |
|
| 730 | + $self2 . |
|
| 731 | + "&var_mode_affiche=boucle#f_$nom_skel'>" . |
|
| 732 | + _T('zbug_boucle') . |
|
| 733 | + "</a></td><td>\n<a class='debug_link_boucle' href='" . |
|
| 734 | + $self2 . |
|
| 735 | + "&var_mode_affiche=resultat#f_$nom_skel'>" . |
|
| 736 | + _T('zbug_resultat') . |
|
| 737 | + "</a></td><td>\n<a class='debug_link_resultat' href='" . |
|
| 738 | + $self2 . |
|
| 739 | + "&var_mode_affiche=code#f_$nom_skel'>" . |
|
| 740 | + _T('zbug_code') . |
|
| 741 | + "</a></td><td>\n<a class='debug_link_resultat' href='" . |
|
| 742 | + str_replace('var_mode=', 'var_profile=', $self2) . |
|
| 743 | + "'>" . |
|
| 744 | + _T('zbug_calcul') . |
|
| 745 | + "</a></td><td>\n" . |
|
| 746 | + (($var_mode_objet == $objet) ? "<b>$nom</b>" : $nom) . |
|
| 747 | + "</td><td>\n" . |
|
| 748 | + $req . |
|
| 749 | + "</td><td>\n" . |
|
| 750 | + spip_htmlspecialchars($crit) . |
|
| 751 | + "</td></tr>"; |
|
| 752 | + } |
|
| 753 | + } |
|
| 754 | + |
|
| 755 | + return $res; |
|
| 756 | 756 | } |
| 757 | 757 | |
| 758 | 758 | function debusquer_source($objet, $affiche) { |
| 759 | - $quoi = $GLOBALS['debug_objets'][$affiche][$objet]; |
|
| 760 | - if (!empty($GLOBALS['debug_objets']['boucle'][$objet]->id_boucle)) { |
|
| 761 | - $nom = $GLOBALS['debug_objets']['boucle'][$objet]->id_boucle; |
|
| 762 | - } else { |
|
| 763 | - $nom = $GLOBALS['debug_objets']['sourcefile'][$objet]; |
|
| 764 | - } |
|
| 765 | - $res2 = ""; |
|
| 766 | - |
|
| 767 | - if ($affiche == 'resultat') { |
|
| 768 | - $legend = $nom; |
|
| 769 | - $req = $GLOBALS['debug_objets']['requete'][$objet]; |
|
| 770 | - if (function_exists('_mysql_traite_query')) { |
|
| 771 | - $c = strtolower(_request('connect')); |
|
| 772 | - $c = $GLOBALS['connexions'][$c ? $c : 0]['prefixe']; |
|
| 773 | - $req = _mysql_traite_query($req, '', $c); |
|
| 774 | - } |
|
| 775 | - // permettre le copier/coller facile |
|
| 776 | - // $res = ancre_texte($req, array(), true); |
|
| 777 | - $res = "<div id='T" . md5($req) . "'>\n<pre>\n" . $req . "</pre>\n</div>\n"; |
|
| 778 | - // formatage et affichage des resultats bruts de la requete |
|
| 779 | - $ress_req = spip_query($req); |
|
| 780 | - $brut_sql = ''; |
|
| 781 | - $num = 1; |
|
| 782 | - // eviter l'affichage de milliers de lignes |
|
| 783 | - // personnalisation possible dans mes_options |
|
| 784 | - $max_aff = defined('_MAX_DEBUG_AFF') ? _MAX_DEBUG_AFF : 50; |
|
| 785 | - while ($retours_sql = sql_fetch($ress_req)) { |
|
| 786 | - if ($num <= $max_aff) { |
|
| 787 | - $brut_sql .= "<h3>" . ($num == 1 ? $num . " sur " . sql_count($ress_req) : $num) . "</h3>"; |
|
| 788 | - $brut_sql .= "<p>"; |
|
| 789 | - foreach ($retours_sql as $key => $val) { |
|
| 790 | - $brut_sql .= "<strong>" . $key . "</strong> => " . spip_htmlspecialchars(couper($val, 150)) . "<br />\n"; |
|
| 791 | - } |
|
| 792 | - $brut_sql .= "</p>"; |
|
| 793 | - } |
|
| 794 | - $num++; |
|
| 795 | - } |
|
| 796 | - $res2 = interdire_scripts($brut_sql); |
|
| 797 | - foreach ($quoi as $view) { |
|
| 798 | - // ne pas afficher les $contexte_inclus |
|
| 799 | - $view = preg_replace(",<\?php.+\?[>],Uims", "", $view); |
|
| 800 | - if ($view) { |
|
| 801 | - $res2 .= "\n<br /><fieldset>" . interdire_scripts($view) . "</fieldset>"; |
|
| 802 | - } |
|
| 803 | - } |
|
| 804 | - |
|
| 805 | - } elseif ($affiche == 'code') { |
|
| 806 | - $legend = $nom; |
|
| 807 | - $res = ancre_texte("<" . "?php\n" . $quoi . "\n?" . ">"); |
|
| 808 | - } elseif ($affiche == 'boucle') { |
|
| 809 | - $legend = _T('zbug_boucle') . ' ' . $nom; |
|
| 810 | - // Le compilateur prefixe le nom des boucles par l'extension du fichier source. |
|
| 811 | - $gram = preg_match('/^([^_]+)_/', $objet, $r) ? $r[1] : ''; |
|
| 812 | - $res = ancre_texte(public_decompiler($quoi, $gram, 0, 'boucle')); |
|
| 813 | - } elseif ($affiche == 'squelette') { |
|
| 814 | - $legend = $GLOBALS['debug_objets']['sourcefile'][$objet]; |
|
| 815 | - $res = ancre_texte($GLOBALS['debug_objets']['squelette'][$objet]); |
|
| 816 | - } |
|
| 817 | - |
|
| 818 | - return array($legend, $res, $res2); |
|
| 759 | + $quoi = $GLOBALS['debug_objets'][$affiche][$objet]; |
|
| 760 | + if (!empty($GLOBALS['debug_objets']['boucle'][$objet]->id_boucle)) { |
|
| 761 | + $nom = $GLOBALS['debug_objets']['boucle'][$objet]->id_boucle; |
|
| 762 | + } else { |
|
| 763 | + $nom = $GLOBALS['debug_objets']['sourcefile'][$objet]; |
|
| 764 | + } |
|
| 765 | + $res2 = ""; |
|
| 766 | + |
|
| 767 | + if ($affiche == 'resultat') { |
|
| 768 | + $legend = $nom; |
|
| 769 | + $req = $GLOBALS['debug_objets']['requete'][$objet]; |
|
| 770 | + if (function_exists('_mysql_traite_query')) { |
|
| 771 | + $c = strtolower(_request('connect')); |
|
| 772 | + $c = $GLOBALS['connexions'][$c ? $c : 0]['prefixe']; |
|
| 773 | + $req = _mysql_traite_query($req, '', $c); |
|
| 774 | + } |
|
| 775 | + // permettre le copier/coller facile |
|
| 776 | + // $res = ancre_texte($req, array(), true); |
|
| 777 | + $res = "<div id='T" . md5($req) . "'>\n<pre>\n" . $req . "</pre>\n</div>\n"; |
|
| 778 | + // formatage et affichage des resultats bruts de la requete |
|
| 779 | + $ress_req = spip_query($req); |
|
| 780 | + $brut_sql = ''; |
|
| 781 | + $num = 1; |
|
| 782 | + // eviter l'affichage de milliers de lignes |
|
| 783 | + // personnalisation possible dans mes_options |
|
| 784 | + $max_aff = defined('_MAX_DEBUG_AFF') ? _MAX_DEBUG_AFF : 50; |
|
| 785 | + while ($retours_sql = sql_fetch($ress_req)) { |
|
| 786 | + if ($num <= $max_aff) { |
|
| 787 | + $brut_sql .= "<h3>" . ($num == 1 ? $num . " sur " . sql_count($ress_req) : $num) . "</h3>"; |
|
| 788 | + $brut_sql .= "<p>"; |
|
| 789 | + foreach ($retours_sql as $key => $val) { |
|
| 790 | + $brut_sql .= "<strong>" . $key . "</strong> => " . spip_htmlspecialchars(couper($val, 150)) . "<br />\n"; |
|
| 791 | + } |
|
| 792 | + $brut_sql .= "</p>"; |
|
| 793 | + } |
|
| 794 | + $num++; |
|
| 795 | + } |
|
| 796 | + $res2 = interdire_scripts($brut_sql); |
|
| 797 | + foreach ($quoi as $view) { |
|
| 798 | + // ne pas afficher les $contexte_inclus |
|
| 799 | + $view = preg_replace(",<\?php.+\?[>],Uims", "", $view); |
|
| 800 | + if ($view) { |
|
| 801 | + $res2 .= "\n<br /><fieldset>" . interdire_scripts($view) . "</fieldset>"; |
|
| 802 | + } |
|
| 803 | + } |
|
| 804 | + |
|
| 805 | + } elseif ($affiche == 'code') { |
|
| 806 | + $legend = $nom; |
|
| 807 | + $res = ancre_texte("<" . "?php\n" . $quoi . "\n?" . ">"); |
|
| 808 | + } elseif ($affiche == 'boucle') { |
|
| 809 | + $legend = _T('zbug_boucle') . ' ' . $nom; |
|
| 810 | + // Le compilateur prefixe le nom des boucles par l'extension du fichier source. |
|
| 811 | + $gram = preg_match('/^([^_]+)_/', $objet, $r) ? $r[1] : ''; |
|
| 812 | + $res = ancre_texte(public_decompiler($quoi, $gram, 0, 'boucle')); |
|
| 813 | + } elseif ($affiche == 'squelette') { |
|
| 814 | + $legend = $GLOBALS['debug_objets']['sourcefile'][$objet]; |
|
| 815 | + $res = ancre_texte($GLOBALS['debug_objets']['squelette'][$objet]); |
|
| 816 | + } |
|
| 817 | + |
|
| 818 | + return array($legend, $res, $res2); |
|
| 819 | 819 | } |
| 820 | 820 | |
| 821 | 821 | // https://code.spip.net/@debusquer_entete |
| 822 | 822 | function debusquer_entete($titre, $corps) { |
| 823 | 823 | |
| 824 | - include_spip('balise/formulaire_admin'); |
|
| 825 | - include_spip('public/assembler'); // pour inclure_balise_dynamique |
|
| 826 | - include_spip('inc/texte'); // pour corriger_typo |
|
| 827 | - |
|
| 828 | - return _DOCTYPE_ECRIRE . |
|
| 829 | - html_lang_attributes() . |
|
| 830 | - "<head>\n<title>" . |
|
| 831 | - ('SPIP ' . $GLOBALS['spip_version_affichee'] . ' ' . |
|
| 832 | - _T('admin_debug') . ' ' . $titre . ' (' . |
|
| 833 | - supprimer_tags(corriger_typo($GLOBALS['meta']['nom_site']))) . |
|
| 834 | - ")</title>\n" . |
|
| 835 | - "<meta http-equiv='Content-Type' content='text/html" . |
|
| 836 | - (($c = $GLOBALS['meta']['charset']) ? "; charset=$c" : '') . |
|
| 837 | - "' />\n" . |
|
| 838 | - http_script('', 'jquery.js') |
|
| 839 | - . "<link rel='stylesheet' href='" . url_absolue(find_in_path('spip_admin.css')) |
|
| 840 | - . "' type='text/css' />" . |
|
| 841 | - "</head>\n" . |
|
| 842 | - "<body style='margin:0 10px;'>\n" . |
|
| 843 | - "<div id='spip-debug-header'>" . |
|
| 844 | - $corps . |
|
| 845 | - inclure_balise_dynamique(balise_FORMULAIRE_ADMIN_dyn('spip-admin-float', $GLOBALS['debug_objets']), false) . |
|
| 846 | - '</div></body></html>'; |
|
| 824 | + include_spip('balise/formulaire_admin'); |
|
| 825 | + include_spip('public/assembler'); // pour inclure_balise_dynamique |
|
| 826 | + include_spip('inc/texte'); // pour corriger_typo |
|
| 827 | + |
|
| 828 | + return _DOCTYPE_ECRIRE . |
|
| 829 | + html_lang_attributes() . |
|
| 830 | + "<head>\n<title>" . |
|
| 831 | + ('SPIP ' . $GLOBALS['spip_version_affichee'] . ' ' . |
|
| 832 | + _T('admin_debug') . ' ' . $titre . ' (' . |
|
| 833 | + supprimer_tags(corriger_typo($GLOBALS['meta']['nom_site']))) . |
|
| 834 | + ")</title>\n" . |
|
| 835 | + "<meta http-equiv='Content-Type' content='text/html" . |
|
| 836 | + (($c = $GLOBALS['meta']['charset']) ? "; charset=$c" : '') . |
|
| 837 | + "' />\n" . |
|
| 838 | + http_script('', 'jquery.js') |
|
| 839 | + . "<link rel='stylesheet' href='" . url_absolue(find_in_path('spip_admin.css')) |
|
| 840 | + . "' type='text/css' />" . |
|
| 841 | + "</head>\n" . |
|
| 842 | + "<body style='margin:0 10px;'>\n" . |
|
| 843 | + "<div id='spip-debug-header'>" . |
|
| 844 | + $corps . |
|
| 845 | + inclure_balise_dynamique(balise_FORMULAIRE_ADMIN_dyn('spip-admin-float', $GLOBALS['debug_objets']), false) . |
|
| 846 | + '</div></body></html>'; |
|
| 847 | 847 | } |
@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | */ |
| 18 | 18 | |
| 19 | 19 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 20 | - return; |
|
| 20 | + return; |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | /** |
@@ -26,22 +26,22 @@ discard block |
||
| 26 | 26 | * @return void |
| 27 | 27 | */ |
| 28 | 28 | function action_relancer_inscription_dist() { |
| 29 | - $securiser_action = charger_fonction('securiser_action', 'inc'); |
|
| 30 | - $id_auteur = $securiser_action(); |
|
| 29 | + $securiser_action = charger_fonction('securiser_action', 'inc'); |
|
| 30 | + $id_auteur = $securiser_action(); |
|
| 31 | 31 | |
| 32 | - if (intval($id_auteur) and autoriser('relancer', 'inscription')) { |
|
| 33 | - $auteur = sql_fetsel('prefs, email, nom, statut', 'spip_auteurs', "id_auteur=$id_auteur"); |
|
| 34 | - if ($auteur['statut'] == 'nouveau') { |
|
| 35 | - include_spip('action/inscrire_auteur'); |
|
| 36 | - action_inscrire_auteur_dist($auteur['prefs'], $auteur['email'], $auteur['nom'], array('force_nouveau' => true)); |
|
| 37 | - } |
|
| 38 | - } elseif ($id_auteur === '*' and autoriser('relancer', 'inscription')) { |
|
| 39 | - $auteurs = sql_allfetsel('prefs, email, nom', 'spip_auteurs', "statut='nouveau'"); |
|
| 40 | - if (is_array($auteurs)) { |
|
| 41 | - include_spip('action/inscrire_auteur'); |
|
| 42 | - while ($row = array_pop($auteurs)) { |
|
| 43 | - action_inscrire_auteur_dist($row['prefs'], $row['email'], $row['nom'], array('force_nouveau' => true)); |
|
| 44 | - } |
|
| 45 | - } |
|
| 46 | - } |
|
| 32 | + if (intval($id_auteur) and autoriser('relancer', 'inscription')) { |
|
| 33 | + $auteur = sql_fetsel('prefs, email, nom, statut', 'spip_auteurs', "id_auteur=$id_auteur"); |
|
| 34 | + if ($auteur['statut'] == 'nouveau') { |
|
| 35 | + include_spip('action/inscrire_auteur'); |
|
| 36 | + action_inscrire_auteur_dist($auteur['prefs'], $auteur['email'], $auteur['nom'], array('force_nouveau' => true)); |
|
| 37 | + } |
|
| 38 | + } elseif ($id_auteur === '*' and autoriser('relancer', 'inscription')) { |
|
| 39 | + $auteurs = sql_allfetsel('prefs, email, nom', 'spip_auteurs', "statut='nouveau'"); |
|
| 40 | + if (is_array($auteurs)) { |
|
| 41 | + include_spip('action/inscrire_auteur'); |
|
| 42 | + while ($row = array_pop($auteurs)) { |
|
| 43 | + action_inscrire_auteur_dist($row['prefs'], $row['email'], $row['nom'], array('force_nouveau' => true)); |
|
| 44 | + } |
|
| 45 | + } |
|
| 46 | + } |
|
| 47 | 47 | } |
@@ -4,364 +4,364 @@ discard block |
||
| 4 | 4 | // ** ne pas modifier le fichier ** |
| 5 | 5 | |
| 6 | 6 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 7 | - return; |
|
| 7 | + return; |
|
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | $GLOBALS[$GLOBALS['idx_lang']] = array( |
| 11 | 11 | |
| 12 | - // A |
|
| 13 | - 'activer_plugin' => 'Attiva il plugin', |
|
| 14 | - 'affichage' => 'Visualizzazione', |
|
| 15 | - 'aide_non_disponible' => 'Questa parte della guida in linea non è ancora disponibile in italiano.', |
|
| 16 | - 'annuler_recherche' => 'Annullare la ricerca', |
|
| 17 | - 'auteur' => 'Autrice:', |
|
| 18 | - 'avis_acces_interdit' => 'Accesso vietato.', |
|
| 19 | - 'avis_article_modifie' => 'Attenzione, @nom_auteur_modif@ ha lavorato su quest’articolo @date_diff@ minuti fa', |
|
| 20 | - 'avis_aucun_resultat' => 'Nessun risultato.', |
|
| 21 | - 'avis_base_inaccessible' => 'Impossibile connettersi al database @base@.', |
|
| 22 | - 'avis_chemin_invalide_1' => 'il percorso che hai scelto', |
|
| 23 | - 'avis_chemin_invalide_2' => 'non sembra valido. Torna alla pagina precedente e verifica le informazioni fornite.', |
|
| 24 | - 'avis_connexion_echec_1' => 'il collegamento alla base di dati è fallito.', |
|
| 25 | - 'avis_connexion_echec_2' => 'torna alla pagina precedente e verifica le informazioni fornite.', |
|
| 26 | - 'avis_connexion_echec_3' => '<b>N.B.</b> Spesso sul server si deve <b>chiedere</b> l’attivazione dell’accesso alla base di dati prima di poterlo utilizzare. Se è impossibile collegarsi, verificare la configurazione per la connessione con l’amministratrice del sistema.', |
|
| 27 | - 'avis_connexion_erreur_nom_base' => 'Il nome del database può contenere solo lettere, cifre e tratti', |
|
| 28 | - 'avis_connexion_ldap_echec_1' => 'La connessione al server LDAP è fallita.', |
|
| 29 | - 'avis_connexion_ldap_echec_2' => 'Torna alla pagina precedente e verifica le informazioni fornite. ', |
|
| 30 | - 'avis_connexion_ldap_echec_3' => 'In alternativa, non utilizzare il supporto LDAP per importare utenti.', |
|
| 31 | - 'avis_deplacement_rubrique' => 'Attenzione! Questa rubrica contiene @contient_breves@ breve/i: se vuoi spostarla, spunta questa casella per confermare.', |
|
| 32 | - 'avis_erreur_connexion_mysql' => 'Errore di connessione SQL', |
|
| 33 | - 'avis_espace_interdit' => '<b>Area vietata</b> <div>SPIP è già installato.</div>', |
|
| 34 | - 'avis_lecture_noms_bases_1' => 'Il programma di installazione non ha potuto leggere i nomi dei database installati nel server.', |
|
| 35 | - 'avis_lecture_noms_bases_2' => 'Nessun database è disponibile, o la funzione che permette di accedere alla lista database è |
|
| 12 | + // A |
|
| 13 | + 'activer_plugin' => 'Attiva il plugin', |
|
| 14 | + 'affichage' => 'Visualizzazione', |
|
| 15 | + 'aide_non_disponible' => 'Questa parte della guida in linea non è ancora disponibile in italiano.', |
|
| 16 | + 'annuler_recherche' => 'Annullare la ricerca', |
|
| 17 | + 'auteur' => 'Autrice:', |
|
| 18 | + 'avis_acces_interdit' => 'Accesso vietato.', |
|
| 19 | + 'avis_article_modifie' => 'Attenzione, @nom_auteur_modif@ ha lavorato su quest’articolo @date_diff@ minuti fa', |
|
| 20 | + 'avis_aucun_resultat' => 'Nessun risultato.', |
|
| 21 | + 'avis_base_inaccessible' => 'Impossibile connettersi al database @base@.', |
|
| 22 | + 'avis_chemin_invalide_1' => 'il percorso che hai scelto', |
|
| 23 | + 'avis_chemin_invalide_2' => 'non sembra valido. Torna alla pagina precedente e verifica le informazioni fornite.', |
|
| 24 | + 'avis_connexion_echec_1' => 'il collegamento alla base di dati è fallito.', |
|
| 25 | + 'avis_connexion_echec_2' => 'torna alla pagina precedente e verifica le informazioni fornite.', |
|
| 26 | + 'avis_connexion_echec_3' => '<b>N.B.</b> Spesso sul server si deve <b>chiedere</b> l’attivazione dell’accesso alla base di dati prima di poterlo utilizzare. Se è impossibile collegarsi, verificare la configurazione per la connessione con l’amministratrice del sistema.', |
|
| 27 | + 'avis_connexion_erreur_nom_base' => 'Il nome del database può contenere solo lettere, cifre e tratti', |
|
| 28 | + 'avis_connexion_ldap_echec_1' => 'La connessione al server LDAP è fallita.', |
|
| 29 | + 'avis_connexion_ldap_echec_2' => 'Torna alla pagina precedente e verifica le informazioni fornite. ', |
|
| 30 | + 'avis_connexion_ldap_echec_3' => 'In alternativa, non utilizzare il supporto LDAP per importare utenti.', |
|
| 31 | + 'avis_deplacement_rubrique' => 'Attenzione! Questa rubrica contiene @contient_breves@ breve/i: se vuoi spostarla, spunta questa casella per confermare.', |
|
| 32 | + 'avis_erreur_connexion_mysql' => 'Errore di connessione SQL', |
|
| 33 | + 'avis_espace_interdit' => '<b>Area vietata</b> <div>SPIP è già installato.</div>', |
|
| 34 | + 'avis_lecture_noms_bases_1' => 'Il programma di installazione non ha potuto leggere i nomi dei database installati nel server.', |
|
| 35 | + 'avis_lecture_noms_bases_2' => 'Nessun database è disponibile, o la funzione che permette di accedere alla lista database è |
|
| 36 | 36 | disattivata per motivi sicurezza (verifica con l’amministratrice di sistema).', |
| 37 | - 'avis_lecture_noms_bases_3' => 'Nel secondo caso, è probabile che un database con il tuo nome di login sia utilizzabile:', |
|
| 38 | - 'avis_non_acces_page' => 'Non hai accesso a questa pagina.', |
|
| 39 | - 'avis_operation_echec' => 'L’operazione è fallita.', |
|
| 40 | - 'avis_operation_impossible' => 'Operazione impossibile', |
|
| 41 | - 'avis_suppression_base' => 'ATTENZIONE, la cancellazione dei dati è irreversibile', |
|
| 37 | + 'avis_lecture_noms_bases_3' => 'Nel secondo caso, è probabile che un database con il tuo nome di login sia utilizzabile:', |
|
| 38 | + 'avis_non_acces_page' => 'Non hai accesso a questa pagina.', |
|
| 39 | + 'avis_operation_echec' => 'L’operazione è fallita.', |
|
| 40 | + 'avis_operation_impossible' => 'Operazione impossibile', |
|
| 41 | + 'avis_suppression_base' => 'ATTENZIONE, la cancellazione dei dati è irreversibile', |
|
| 42 | 42 | |
| 43 | - // B |
|
| 44 | - 'bouton_acces_ldap' => 'Aggiungi l’accesso a LDAP', |
|
| 45 | - 'bouton_ajouter' => 'Aggiungi', |
|
| 46 | - 'bouton_annuler' => 'Annulla', |
|
| 47 | - 'bouton_cache_activer' => 'Riattivare la cache', |
|
| 48 | - 'bouton_cache_desactiver' => 'Disattivare temporaneamente la cache', |
|
| 49 | - 'bouton_demande_publication' => 'Chiedi la pubblicazione di questo articolo', |
|
| 50 | - 'bouton_desactive_tout' => 'Disattiva tutto', |
|
| 51 | - 'bouton_desinstaller' => 'Disinstalla', |
|
| 52 | - 'bouton_effacer_tout' => 'Cancella TUTTO', |
|
| 53 | - 'bouton_envoyer_message' => 'Messaggio definitivo: Invia', |
|
| 54 | - 'bouton_fermer' => 'Chiudere', |
|
| 55 | - 'bouton_mettre_a_jour_base' => 'Aggiornare il database', |
|
| 56 | - 'bouton_modifier' => 'Modifica', |
|
| 57 | - 'bouton_radio_afficher' => 'Visualizza', |
|
| 58 | - 'bouton_radio_apparaitre_liste_redacteurs_connectes' => 'Comparire nell’elenco delle redattrici collegate', |
|
| 59 | - 'bouton_radio_envoi_annonces_adresse' => 'Invia gli annunci all’indirizzo:', |
|
| 60 | - 'bouton_radio_envoi_liste_nouveautes' => 'Invia l’elenco delle novità', |
|
| 61 | - 'bouton_radio_non_apparaitre_liste_redacteurs_connectes' => 'Non comparire nell’elenco delle redattrici collegate ', |
|
| 62 | - 'bouton_radio_non_envoi_annonces_editoriales' => 'Non inviare annunci editoriali ', |
|
| 63 | - 'bouton_redirection' => 'REINDIRIZZAMENTO', |
|
| 64 | - 'bouton_relancer_installation' => 'Rilanciare l’installazione', |
|
| 65 | - 'bouton_suivant' => 'Avanti', |
|
| 66 | - 'bouton_tenter_recuperation' => 'Tentare un ripristino', |
|
| 67 | - 'bouton_test_proxy' => 'Testare il proxy', |
|
| 68 | - 'bouton_vider_cache' => 'Svuota la cache', |
|
| 43 | + // B |
|
| 44 | + 'bouton_acces_ldap' => 'Aggiungi l’accesso a LDAP', |
|
| 45 | + 'bouton_ajouter' => 'Aggiungi', |
|
| 46 | + 'bouton_annuler' => 'Annulla', |
|
| 47 | + 'bouton_cache_activer' => 'Riattivare la cache', |
|
| 48 | + 'bouton_cache_desactiver' => 'Disattivare temporaneamente la cache', |
|
| 49 | + 'bouton_demande_publication' => 'Chiedi la pubblicazione di questo articolo', |
|
| 50 | + 'bouton_desactive_tout' => 'Disattiva tutto', |
|
| 51 | + 'bouton_desinstaller' => 'Disinstalla', |
|
| 52 | + 'bouton_effacer_tout' => 'Cancella TUTTO', |
|
| 53 | + 'bouton_envoyer_message' => 'Messaggio definitivo: Invia', |
|
| 54 | + 'bouton_fermer' => 'Chiudere', |
|
| 55 | + 'bouton_mettre_a_jour_base' => 'Aggiornare il database', |
|
| 56 | + 'bouton_modifier' => 'Modifica', |
|
| 57 | + 'bouton_radio_afficher' => 'Visualizza', |
|
| 58 | + 'bouton_radio_apparaitre_liste_redacteurs_connectes' => 'Comparire nell’elenco delle redattrici collegate', |
|
| 59 | + 'bouton_radio_envoi_annonces_adresse' => 'Invia gli annunci all’indirizzo:', |
|
| 60 | + 'bouton_radio_envoi_liste_nouveautes' => 'Invia l’elenco delle novità', |
|
| 61 | + 'bouton_radio_non_apparaitre_liste_redacteurs_connectes' => 'Non comparire nell’elenco delle redattrici collegate ', |
|
| 62 | + 'bouton_radio_non_envoi_annonces_editoriales' => 'Non inviare annunci editoriali ', |
|
| 63 | + 'bouton_redirection' => 'REINDIRIZZAMENTO', |
|
| 64 | + 'bouton_relancer_installation' => 'Rilanciare l’installazione', |
|
| 65 | + 'bouton_suivant' => 'Avanti', |
|
| 66 | + 'bouton_tenter_recuperation' => 'Tentare un ripristino', |
|
| 67 | + 'bouton_test_proxy' => 'Testare il proxy', |
|
| 68 | + 'bouton_vider_cache' => 'Svuota la cache', |
|
| 69 | 69 | |
| 70 | - // C |
|
| 71 | - 'cache_modifiable_webmestre' => 'Questo parametro può essere modificato dalla webmistress del sito.', |
|
| 72 | - 'calendrier_synchro' => 'Se si utilizza un programma di agenda compatibile con <b>iCal</b>, è possibile sincronizzare i dati con le informazioni di questo sito', |
|
| 73 | - 'config_activer_champs' => 'Attiva i campi seguenti', |
|
| 74 | - 'config_choix_base_sup' => 'indicare un database su questo server', |
|
| 75 | - 'config_erreur_base_sup' => 'SPIP non ha accesso all’elenco dei database accessibili ', |
|
| 76 | - 'config_info_base_sup' => 'Se si hanno altri database da interrogare attraverso SPIP, con il proprio server SQL o altro, il form sottostante permette di dichiararli. Se si lasciano alcuni campi vuoti verranno utilizzati i dati della connessione al database principale.', |
|
| 77 | - 'config_info_base_sup_disponibles' => 'Database supplementari già dichiarati:', |
|
| 78 | - 'config_info_enregistree' => 'La nuova configurazione è stata registrata', |
|
| 79 | - 'config_info_logos' => 'Ogni elemento del sito può avere un logo, come pure un « logo per il roll-over »', |
|
| 80 | - 'config_info_logos_utiliser' => 'Utilizza i logo', |
|
| 81 | - 'config_info_logos_utiliser_non' => 'Non utilizzare i logo', |
|
| 82 | - 'config_info_logos_utiliser_survol' => 'Utilizzare i logo di roll-over', |
|
| 83 | - 'config_info_logos_utiliser_survol_non' => 'Non utilizzare i logo di roll-over', |
|
| 84 | - 'config_info_redirection' => 'Attivando questa opzione è possibile creare degli articoli virtuali, semplici riferimenti di articoli pubblicati su altri siti o al di fuori di SPIP.', |
|
| 85 | - 'config_redirection' => 'Articoli virtuali', |
|
| 86 | - 'config_titre_base_sup' => 'Dichiarazione di un database supplementare', |
|
| 87 | - 'config_titre_base_sup_choix' => 'Scegliere un database supplementare', |
|
| 88 | - 'connexion_ldap' => 'Connessione:', |
|
| 89 | - 'creer_et_associer_un_auteur' => 'Creare ed associare un’autrice', |
|
| 70 | + // C |
|
| 71 | + 'cache_modifiable_webmestre' => 'Questo parametro può essere modificato dalla webmistress del sito.', |
|
| 72 | + 'calendrier_synchro' => 'Se si utilizza un programma di agenda compatibile con <b>iCal</b>, è possibile sincronizzare i dati con le informazioni di questo sito', |
|
| 73 | + 'config_activer_champs' => 'Attiva i campi seguenti', |
|
| 74 | + 'config_choix_base_sup' => 'indicare un database su questo server', |
|
| 75 | + 'config_erreur_base_sup' => 'SPIP non ha accesso all’elenco dei database accessibili ', |
|
| 76 | + 'config_info_base_sup' => 'Se si hanno altri database da interrogare attraverso SPIP, con il proprio server SQL o altro, il form sottostante permette di dichiararli. Se si lasciano alcuni campi vuoti verranno utilizzati i dati della connessione al database principale.', |
|
| 77 | + 'config_info_base_sup_disponibles' => 'Database supplementari già dichiarati:', |
|
| 78 | + 'config_info_enregistree' => 'La nuova configurazione è stata registrata', |
|
| 79 | + 'config_info_logos' => 'Ogni elemento del sito può avere un logo, come pure un « logo per il roll-over »', |
|
| 80 | + 'config_info_logos_utiliser' => 'Utilizza i logo', |
|
| 81 | + 'config_info_logos_utiliser_non' => 'Non utilizzare i logo', |
|
| 82 | + 'config_info_logos_utiliser_survol' => 'Utilizzare i logo di roll-over', |
|
| 83 | + 'config_info_logos_utiliser_survol_non' => 'Non utilizzare i logo di roll-over', |
|
| 84 | + 'config_info_redirection' => 'Attivando questa opzione è possibile creare degli articoli virtuali, semplici riferimenti di articoli pubblicati su altri siti o al di fuori di SPIP.', |
|
| 85 | + 'config_redirection' => 'Articoli virtuali', |
|
| 86 | + 'config_titre_base_sup' => 'Dichiarazione di un database supplementare', |
|
| 87 | + 'config_titre_base_sup_choix' => 'Scegliere un database supplementare', |
|
| 88 | + 'connexion_ldap' => 'Connessione:', |
|
| 89 | + 'creer_et_associer_un_auteur' => 'Creare ed associare un’autrice', |
|
| 90 | 90 | |
| 91 | - // D |
|
| 92 | - 'date_mot_heures' => 'ore', |
|
| 91 | + // D |
|
| 92 | + 'date_mot_heures' => 'ore', |
|
| 93 | 93 | |
| 94 | - // E |
|
| 95 | - 'ecran_securite' => ' + schermo di sicurezza @version@', # RELIRE |
|
| 96 | - 'email' => 'email', |
|
| 97 | - 'email_2' => 'email:', |
|
| 98 | - 'en_savoir_plus' => 'Ulteriori informazioni', # RELIRE |
|
| 99 | - 'entree_adresse_annuaire' => 'Indirizzo della rubrica', |
|
| 100 | - 'entree_adresse_email' => 'Il tuo indirizzo email', |
|
| 101 | - 'entree_adresse_email_2' => 'Indirizzo email', |
|
| 102 | - 'entree_base_donnee_1' => 'Indirizzo del database', |
|
| 103 | - 'entree_base_donnee_2' => '(Spesso questo indirizzo coincide con quello dell’intero sito, qualche volta corrisponde a "localhost", altre volte invece non è necessario specificarlo.)', |
|
| 104 | - 'entree_biographie' => 'La tua biografia in breve.', |
|
| 105 | - 'entree_chemin_acces' => '<b>Inserire</b> il percorso d’accesso:', |
|
| 106 | - 'entree_cle_pgp' => 'Chiave PGP', |
|
| 107 | - 'entree_cle_pgp_2' => 'Autenticazione', # RELIRE |
|
| 108 | - 'entree_contenu_rubrique' => '(Contenuto della rubrica in qualche parola)', |
|
| 109 | - 'entree_identifiants_connexion' => 'Identificativo di connessione...', |
|
| 110 | - 'entree_identifiants_connexion_2' => 'Identificativo', # RELIRE |
|
| 111 | - 'entree_informations_connexion_ldap' => 'Inserisci in questo form gli estremi per la connessione alla tua rubrica LDAP. |
|
| 94 | + // E |
|
| 95 | + 'ecran_securite' => ' + schermo di sicurezza @version@', # RELIRE |
|
| 96 | + 'email' => 'email', |
|
| 97 | + 'email_2' => 'email:', |
|
| 98 | + 'en_savoir_plus' => 'Ulteriori informazioni', # RELIRE |
|
| 99 | + 'entree_adresse_annuaire' => 'Indirizzo della rubrica', |
|
| 100 | + 'entree_adresse_email' => 'Il tuo indirizzo email', |
|
| 101 | + 'entree_adresse_email_2' => 'Indirizzo email', |
|
| 102 | + 'entree_base_donnee_1' => 'Indirizzo del database', |
|
| 103 | + 'entree_base_donnee_2' => '(Spesso questo indirizzo coincide con quello dell’intero sito, qualche volta corrisponde a "localhost", altre volte invece non è necessario specificarlo.)', |
|
| 104 | + 'entree_biographie' => 'La tua biografia in breve.', |
|
| 105 | + 'entree_chemin_acces' => '<b>Inserire</b> il percorso d’accesso:', |
|
| 106 | + 'entree_cle_pgp' => 'Chiave PGP', |
|
| 107 | + 'entree_cle_pgp_2' => 'Autenticazione', # RELIRE |
|
| 108 | + 'entree_contenu_rubrique' => '(Contenuto della rubrica in qualche parola)', |
|
| 109 | + 'entree_identifiants_connexion' => 'Identificativo di connessione...', |
|
| 110 | + 'entree_identifiants_connexion_2' => 'Identificativo', # RELIRE |
|
| 111 | + 'entree_informations_connexion_ldap' => 'Inserisci in questo form gli estremi per la connessione alla tua rubrica LDAP. |
|
| 112 | 112 | Se non conosci queste informazioni, richiedile all’amministratrice del sistema o della rete.', |
| 113 | - 'entree_infos_perso' => 'Chi sei?', |
|
| 114 | - 'entree_infos_perso_2' => 'Chi è l’autrice ?', |
|
| 115 | - 'entree_interieur_rubrique' => 'All’interno della rubrica:', |
|
| 116 | - 'entree_liens_sites' => '<b>Link ipertestuale</b> (riferimento, sito da visitare...)', |
|
| 117 | - 'entree_login' => 'Login', |
|
| 118 | - 'entree_login_connexion_1' => 'Il login di connessione', |
|
| 119 | - 'entree_login_connexion_2' => '(Corrisponde a volte al login d’accesso via FTP; in alcuni casi non occorre specificare nulla)', |
|
| 120 | - 'entree_mot_passe' => 'Password', |
|
| 121 | - 'entree_mot_passe_1' => 'La password di connessione', |
|
| 122 | - 'entree_mot_passe_2' => '(Corrisponde a volte alla password d’accesso via FTP; in alcuni casi non occorre specificare nulla)', |
|
| 123 | - 'entree_nom_fichier' => 'Inserire il nome del file @texte_compresse@:', |
|
| 124 | - 'entree_nom_pseudo' => 'Nome o pseudonimo', |
|
| 125 | - 'entree_nom_pseudo_1' => '(Nome o pseudonimo)', |
|
| 126 | - 'entree_nom_pseudo_2' => 'Nome o pseudonimo', |
|
| 127 | - 'entree_nom_site' => 'Nome del tuo sito', |
|
| 128 | - 'entree_nom_site_2' => 'Nome del sito dell’autrice', # RELIRE |
|
| 129 | - 'entree_nouveau_passe' => 'Nuova password', |
|
| 130 | - 'entree_passe_ldap' => 'Password', |
|
| 131 | - 'entree_port_annuaire' => 'Il numero di porta della rubrica', |
|
| 132 | - 'entree_signature' => 'Firma', |
|
| 133 | - 'entree_titre_obligatoire' => '<b>Titolo</b> [Obbligatorio]<br />', |
|
| 134 | - 'entree_url' => 'Indirizzo (URL) del sito', |
|
| 135 | - 'entree_url_2' => 'Indirizzo (URL) del sito', |
|
| 136 | - 'erreur_connect_deja_existant' => 'Esiste già un server con questo nome', # RELIRE |
|
| 137 | - 'erreur_email_deja_existant' => 'Questo indirizzo email è già registrato', |
|
| 138 | - 'erreur_nom_connect_incorrect' => 'Questo nome non è autorizzato', # RELIRE |
|
| 139 | - 'erreur_plugin_desinstalation_echouee' => 'La disinstallazione del plug in è fallita. E’ comunque possibile disattivarlo.', # RELIRE |
|
| 140 | - 'erreur_plugin_fichier_absent' => 'File non presente', |
|
| 141 | - 'erreur_plugin_fichier_def_absent' => 'File di definizioni non presente', |
|
| 142 | - 'erreur_plugin_nom_fonction_interdit' => 'Nome di funzione non possibile', |
|
| 143 | - 'erreur_plugin_nom_manquant' => 'Nome del plugin mancante', |
|
| 144 | - 'erreur_plugin_prefix_manquant' => 'Spazio per il nome del plugin non definito', |
|
| 145 | - 'erreur_plugin_tag_plugin_absent' => '<plugin> mancante nel file di definizione', |
|
| 146 | - 'erreur_plugin_version_manquant' => 'Versione del plugin mancante', |
|
| 113 | + 'entree_infos_perso' => 'Chi sei?', |
|
| 114 | + 'entree_infos_perso_2' => 'Chi è l’autrice ?', |
|
| 115 | + 'entree_interieur_rubrique' => 'All’interno della rubrica:', |
|
| 116 | + 'entree_liens_sites' => '<b>Link ipertestuale</b> (riferimento, sito da visitare...)', |
|
| 117 | + 'entree_login' => 'Login', |
|
| 118 | + 'entree_login_connexion_1' => 'Il login di connessione', |
|
| 119 | + 'entree_login_connexion_2' => '(Corrisponde a volte al login d’accesso via FTP; in alcuni casi non occorre specificare nulla)', |
|
| 120 | + 'entree_mot_passe' => 'Password', |
|
| 121 | + 'entree_mot_passe_1' => 'La password di connessione', |
|
| 122 | + 'entree_mot_passe_2' => '(Corrisponde a volte alla password d’accesso via FTP; in alcuni casi non occorre specificare nulla)', |
|
| 123 | + 'entree_nom_fichier' => 'Inserire il nome del file @texte_compresse@:', |
|
| 124 | + 'entree_nom_pseudo' => 'Nome o pseudonimo', |
|
| 125 | + 'entree_nom_pseudo_1' => '(Nome o pseudonimo)', |
|
| 126 | + 'entree_nom_pseudo_2' => 'Nome o pseudonimo', |
|
| 127 | + 'entree_nom_site' => 'Nome del tuo sito', |
|
| 128 | + 'entree_nom_site_2' => 'Nome del sito dell’autrice', # RELIRE |
|
| 129 | + 'entree_nouveau_passe' => 'Nuova password', |
|
| 130 | + 'entree_passe_ldap' => 'Password', |
|
| 131 | + 'entree_port_annuaire' => 'Il numero di porta della rubrica', |
|
| 132 | + 'entree_signature' => 'Firma', |
|
| 133 | + 'entree_titre_obligatoire' => '<b>Titolo</b> [Obbligatorio]<br />', |
|
| 134 | + 'entree_url' => 'Indirizzo (URL) del sito', |
|
| 135 | + 'entree_url_2' => 'Indirizzo (URL) del sito', |
|
| 136 | + 'erreur_connect_deja_existant' => 'Esiste già un server con questo nome', # RELIRE |
|
| 137 | + 'erreur_email_deja_existant' => 'Questo indirizzo email è già registrato', |
|
| 138 | + 'erreur_nom_connect_incorrect' => 'Questo nome non è autorizzato', # RELIRE |
|
| 139 | + 'erreur_plugin_desinstalation_echouee' => 'La disinstallazione del plug in è fallita. E’ comunque possibile disattivarlo.', # RELIRE |
|
| 140 | + 'erreur_plugin_fichier_absent' => 'File non presente', |
|
| 141 | + 'erreur_plugin_fichier_def_absent' => 'File di definizioni non presente', |
|
| 142 | + 'erreur_plugin_nom_fonction_interdit' => 'Nome di funzione non possibile', |
|
| 143 | + 'erreur_plugin_nom_manquant' => 'Nome del plugin mancante', |
|
| 144 | + 'erreur_plugin_prefix_manquant' => 'Spazio per il nome del plugin non definito', |
|
| 145 | + 'erreur_plugin_tag_plugin_absent' => '<plugin> mancante nel file di definizione', |
|
| 146 | + 'erreur_plugin_version_manquant' => 'Versione del plugin mancante', |
|
| 147 | 147 | |
| 148 | - // H |
|
| 149 | - 'htaccess_a_simuler' => 'Attenzione: la configurazione del vostro server HTTP non tiene conto dei file @htaccess@. Per poter mettere in sicurezza bisognerà modificare la configurazione di questo punto, oppure sarà necessario che i parametri fissi @constantes@ (definiti nel file le_mie_opzioni.php) abbiano i valore dei registri diversi da @document_root@.', # RELIRE |
|
| 148 | + // H |
|
| 149 | + 'htaccess_a_simuler' => 'Attenzione: la configurazione del vostro server HTTP non tiene conto dei file @htaccess@. Per poter mettere in sicurezza bisognerà modificare la configurazione di questo punto, oppure sarà necessario che i parametri fissi @constantes@ (definiti nel file le_mie_opzioni.php) abbiano i valore dei registri diversi da @document_root@.', # RELIRE |
|
| 150 | 150 | |
| 151 | - // I |
|
| 152 | - 'ical_info1' => 'Questa pagina elenca diversi metodi per rimanere in contatto con le varie attività del sito.', |
|
| 153 | - 'ical_info2' => 'Per ulteriori informazioni su tutte queste tecniche, non esitate a consultare <a href="@spipnet@">la documentazione di SPIP</a>.', |
|
| 154 | - 'ical_info_calendrier' => 'Sono disponibili due calendari. Il primo è una mappa del sito che annuncia tutti gli articoli pubblicati. Il secondo contiene gli annunci editoriali e gli ultimi messaggi privati: è un’area riservata, mediante identificativo personale, che è possibile modificare in qualsiasi momento rinnovando la password personale.', |
|
| 155 | - 'ical_methode_http' => 'Download', |
|
| 156 | - 'ical_methode_webcal' => 'Sincronizzazione (webcal://)', |
|
| 157 | - 'ical_texte_js' => 'Una linea in javascript permette di visualizzare, con molta semplicità e su qualsiasi tipo di sito, gli articoli recenti pubblicati su questo sito.', |
|
| 158 | - 'ical_texte_prive' => 'Questo calendario, ad uso strettamente privato, dà informazioni sull’attività redazionale privata di questo sito (impegni e appuntamenti personali, articoli e brevi proposti...).', |
|
| 159 | - 'ical_texte_public' => 'Questo calendario permette di monitorare l’attività pubblica del sito (articoli e brevi pubblicati).', |
|
| 160 | - 'ical_texte_rss' => 'È possibile mettere in syndication le novità di questo sito con qualsiasi lettore di file in formato XML/RSS (Rich Site Summary). Questo è il medesimo formato che permette a SPIP di leggere le novità pubblicate su altri siti che utilizzano un formato di scambio compatibile.', |
|
| 161 | - 'ical_titre_js' => 'Javascript', |
|
| 162 | - 'ical_titre_mailing' => 'Mailing-list', |
|
| 163 | - 'ical_titre_rss' => 'File di syndication', |
|
| 164 | - 'icone_activer_cookie' => 'Attiva il cookie di corrispondenza', |
|
| 165 | - 'icone_activite' => 'Attività', |
|
| 166 | - 'icone_admin_plugin' => 'Gestione dei plugin', |
|
| 167 | - 'icone_afficher_auteurs' => 'Pubblica le autrici', |
|
| 168 | - 'icone_afficher_visiteurs' => 'Pubblica i visitatori', |
|
| 169 | - 'icone_arret_discussion' => 'Non partecipare più a questa discussione', |
|
| 170 | - 'icone_calendrier' => 'Calendario', |
|
| 171 | - 'icone_creer_auteur' => 'Crea una nuova autrice ed associala a questo articolo', |
|
| 172 | - 'icone_creer_mot_cle' => 'Crea una nuova parola chiave e collegala a questo articolo', |
|
| 173 | - 'icone_creer_rubrique_2' => 'Crea una nuova rubrica', |
|
| 174 | - 'icone_ma_langue' => 'La mia lingua', |
|
| 175 | - 'icone_mes_infos' => 'Le mie informazioni', |
|
| 176 | - 'icone_modifier_article' => 'Modifica l’articolo', |
|
| 177 | - 'icone_modifier_rubrique' => 'Modifica la rubrica', |
|
| 178 | - 'icone_relancer_signataire' => 'Rilanciare il firmatario', |
|
| 179 | - 'icone_retour' => 'Indietro', |
|
| 180 | - 'icone_retour_article' => 'Torna all’articolo', |
|
| 181 | - 'icone_supprimer_cookie' => 'Elimina il cookie di corrispondenza', |
|
| 182 | - 'icone_supprimer_rubrique' => 'Elimina la rubrica', |
|
| 183 | - 'icone_supprimer_signature' => 'Cancella l’adesione', |
|
| 184 | - 'icone_valider_signature' => 'Conferma l’adesione', |
|
| 185 | - 'image_administrer_rubrique' => 'Puoi amministrare questa rubrica', |
|
| 186 | - 'impossible_modifier_login_auteur' => 'Impossible de modifier le login.', # MODIF |
|
| 187 | - 'impossible_modifier_pass_auteur' => 'Impossible de modifier le mot de passe.', # MODIF |
|
| 188 | - 'info_1_article' => '1 articolo', |
|
| 189 | - 'info_activer_cookie' => 'Se vuoi puoi attivare un <b>cookie di corrispondenza</b>, che ti permetterà |
|
| 151 | + // I |
|
| 152 | + 'ical_info1' => 'Questa pagina elenca diversi metodi per rimanere in contatto con le varie attività del sito.', |
|
| 153 | + 'ical_info2' => 'Per ulteriori informazioni su tutte queste tecniche, non esitate a consultare <a href="@spipnet@">la documentazione di SPIP</a>.', |
|
| 154 | + 'ical_info_calendrier' => 'Sono disponibili due calendari. Il primo è una mappa del sito che annuncia tutti gli articoli pubblicati. Il secondo contiene gli annunci editoriali e gli ultimi messaggi privati: è un’area riservata, mediante identificativo personale, che è possibile modificare in qualsiasi momento rinnovando la password personale.', |
|
| 155 | + 'ical_methode_http' => 'Download', |
|
| 156 | + 'ical_methode_webcal' => 'Sincronizzazione (webcal://)', |
|
| 157 | + 'ical_texte_js' => 'Una linea in javascript permette di visualizzare, con molta semplicità e su qualsiasi tipo di sito, gli articoli recenti pubblicati su questo sito.', |
|
| 158 | + 'ical_texte_prive' => 'Questo calendario, ad uso strettamente privato, dà informazioni sull’attività redazionale privata di questo sito (impegni e appuntamenti personali, articoli e brevi proposti...).', |
|
| 159 | + 'ical_texte_public' => 'Questo calendario permette di monitorare l’attività pubblica del sito (articoli e brevi pubblicati).', |
|
| 160 | + 'ical_texte_rss' => 'È possibile mettere in syndication le novità di questo sito con qualsiasi lettore di file in formato XML/RSS (Rich Site Summary). Questo è il medesimo formato che permette a SPIP di leggere le novità pubblicate su altri siti che utilizzano un formato di scambio compatibile.', |
|
| 161 | + 'ical_titre_js' => 'Javascript', |
|
| 162 | + 'ical_titre_mailing' => 'Mailing-list', |
|
| 163 | + 'ical_titre_rss' => 'File di syndication', |
|
| 164 | + 'icone_activer_cookie' => 'Attiva il cookie di corrispondenza', |
|
| 165 | + 'icone_activite' => 'Attività', |
|
| 166 | + 'icone_admin_plugin' => 'Gestione dei plugin', |
|
| 167 | + 'icone_afficher_auteurs' => 'Pubblica le autrici', |
|
| 168 | + 'icone_afficher_visiteurs' => 'Pubblica i visitatori', |
|
| 169 | + 'icone_arret_discussion' => 'Non partecipare più a questa discussione', |
|
| 170 | + 'icone_calendrier' => 'Calendario', |
|
| 171 | + 'icone_creer_auteur' => 'Crea una nuova autrice ed associala a questo articolo', |
|
| 172 | + 'icone_creer_mot_cle' => 'Crea una nuova parola chiave e collegala a questo articolo', |
|
| 173 | + 'icone_creer_rubrique_2' => 'Crea una nuova rubrica', |
|
| 174 | + 'icone_ma_langue' => 'La mia lingua', |
|
| 175 | + 'icone_mes_infos' => 'Le mie informazioni', |
|
| 176 | + 'icone_modifier_article' => 'Modifica l’articolo', |
|
| 177 | + 'icone_modifier_rubrique' => 'Modifica la rubrica', |
|
| 178 | + 'icone_relancer_signataire' => 'Rilanciare il firmatario', |
|
| 179 | + 'icone_retour' => 'Indietro', |
|
| 180 | + 'icone_retour_article' => 'Torna all’articolo', |
|
| 181 | + 'icone_supprimer_cookie' => 'Elimina il cookie di corrispondenza', |
|
| 182 | + 'icone_supprimer_rubrique' => 'Elimina la rubrica', |
|
| 183 | + 'icone_supprimer_signature' => 'Cancella l’adesione', |
|
| 184 | + 'icone_valider_signature' => 'Conferma l’adesione', |
|
| 185 | + 'image_administrer_rubrique' => 'Puoi amministrare questa rubrica', |
|
| 186 | + 'impossible_modifier_login_auteur' => 'Impossible de modifier le login.', # MODIF |
|
| 187 | + 'impossible_modifier_pass_auteur' => 'Impossible de modifier le mot de passe.', # MODIF |
|
| 188 | + 'info_1_article' => '1 articolo', |
|
| 189 | + 'info_activer_cookie' => 'Se vuoi puoi attivare un <b>cookie di corrispondenza</b>, che ti permetterà |
|
| 190 | 190 | di passare facilmente dal sito pubblico all’interfaccia privata.', |
| 191 | - 'info_administrateur' => 'Amministratrice', |
|
| 192 | - 'info_administrateur_1' => 'Amministratrice', |
|
| 193 | - 'info_administrateur_2' => 'del sito (<i>da utilizzare con prudenza</i>)', |
|
| 194 | - 'info_administrateur_site_01' => 'Se sei amministratrice del sito,', |
|
| 195 | - 'info_administrateur_site_02' => 'clicca qui', |
|
| 196 | - 'info_administrateurs' => 'Amministratrici', |
|
| 197 | - 'info_administrer_rubrique' => 'Puoi amministrare questa rubrica', |
|
| 198 | - 'info_adresse' => 'all’indirizzo:', |
|
| 199 | - 'info_adresse_url' => 'Indirizzo (URL) del sito pubblico', |
|
| 200 | - 'info_aide_en_ligne' => 'Guida in linea SPIP', |
|
| 201 | - 'info_ajout_image' => 'Quando aggiungi delle immagini come documenti allegati ad un articolo, |
|
| 191 | + 'info_administrateur' => 'Amministratrice', |
|
| 192 | + 'info_administrateur_1' => 'Amministratrice', |
|
| 193 | + 'info_administrateur_2' => 'del sito (<i>da utilizzare con prudenza</i>)', |
|
| 194 | + 'info_administrateur_site_01' => 'Se sei amministratrice del sito,', |
|
| 195 | + 'info_administrateur_site_02' => 'clicca qui', |
|
| 196 | + 'info_administrateurs' => 'Amministratrici', |
|
| 197 | + 'info_administrer_rubrique' => 'Puoi amministrare questa rubrica', |
|
| 198 | + 'info_adresse' => 'all’indirizzo:', |
|
| 199 | + 'info_adresse_url' => 'Indirizzo (URL) del sito pubblico', |
|
| 200 | + 'info_aide_en_ligne' => 'Guida in linea SPIP', |
|
| 201 | + 'info_ajout_image' => 'Quando aggiungi delle immagini come documenti allegati ad un articolo, |
|
| 202 | 202 | SPIP può creare delle thumbnail (miniature) delle |
| 203 | 203 | immagini inserite. Ciò permette ad esempio di creare in automatico una galleria di immagini o un portfolio.', |
| 204 | - 'info_ajouter_rubrique' => 'Aggiungi un’altra rubrica da amministrare:', |
|
| 205 | - 'info_annonce_nouveautes' => 'Annuncio delle novità', |
|
| 206 | - 'info_article' => 'articolo', |
|
| 207 | - 'info_article_2' => 'articoli', |
|
| 208 | - 'info_article_a_paraitre' => 'Gli articoli postdatati da pubblicare', |
|
| 209 | - 'info_articles_02' => 'articoli', |
|
| 210 | - 'info_articles_2' => 'Articoli', |
|
| 211 | - 'info_articles_auteur' => 'Articoli di questo autore', |
|
| 212 | - 'info_articles_trouves' => 'Articoli trovati', |
|
| 213 | - 'info_attente_validation' => 'I tuoi articoli in attesa di convalida', |
|
| 214 | - 'info_aujourdhui' => 'oggi: ', |
|
| 215 | - 'info_auteurs' => 'Le autrici', |
|
| 216 | - 'info_auteurs_par_tri' => 'Autrici@partri@', |
|
| 217 | - 'info_auteurs_trouves' => 'Autrici trovate', |
|
| 218 | - 'info_authentification_externe' => 'Autenticazione esterna', |
|
| 219 | - 'info_avertissement' => 'Avvertimento', |
|
| 220 | - 'info_barre_outils' => 'con la barra degli strumenti?', |
|
| 221 | - 'info_base_installee' => 'La struttura del vostro database è installata.', |
|
| 222 | - 'info_chapeau' => 'Introduzione', |
|
| 223 | - 'info_chapeau_2' => 'Introduzione:', |
|
| 224 | - 'info_chemin_acces_1' => 'Opzioni: <b>Percorso d’accesso ai dati nell’elenco</b>', |
|
| 225 | - 'info_chemin_acces_2' => 'È necessario specificare il percorso per accedere ai dati nell’elenco. Questa informazione è indispensabile al fine di leggere i profili utente in esso contenuti.', |
|
| 226 | - 'info_chemin_acces_annuaire' => 'Opzioni: <b>Percorso d’accesso ai dati nell’elenco', |
|
| 227 | - 'info_choix_base' => 'Terza fase: ', |
|
| 228 | - 'info_classement_1' => '<sup>o</sup> su @liste@', |
|
| 229 | - 'info_classement_2' => '<sup>o</sup> su @liste@', |
|
| 230 | - 'info_code_acces' => 'Non dimenticare i tuoi codici d’accesso!', |
|
| 231 | - 'info_config_suivi' => 'Se questo indirizzo corrisponde a una mailing-list, è possibile indicare qui sotto l’indirizzo al quale i partecipanti del sito possono iscriversi. Questo indirizzo può essere una URL (per esempio la pagina di iscrizione via Web alla lista), oppure un indirizzo email che contiene un Oggetto specifico (per esempio: <tt>@adresse_suivi@?subject=subscribe</tt>):', |
|
| 232 | - 'info_config_suivi_explication' => 'È possibile abbonarsi alla mailing-list di questo sito. Verranno spedite per email le notifiche degli articoli e delle brevi proposte per la pubblicazione.', |
|
| 233 | - 'info_confirmer_passe' => 'Conferma la nuova password:', |
|
| 234 | - 'info_conflit_edition_avis_non_sauvegarde' => 'Attenzione, i campi seguenti sono già stati modificati. Quindi le vostre modifiche su questi campi non sono state registrate.', |
|
| 235 | - 'info_conflit_edition_differences' => 'Differenze:', |
|
| 236 | - 'info_conflit_edition_version_enregistree' => 'La versione registrata:', |
|
| 237 | - 'info_conflit_edition_votre_version' => 'La tua versione:', |
|
| 238 | - 'info_connexion_base' => 'Prova di connessione al database', |
|
| 239 | - 'info_connexion_base_donnee' => 'Connessione al proprio database', |
|
| 240 | - 'info_connexion_ldap_ok' => 'La connessione LDAP è riuscita.</b><p> È possibile passare alla fase successiva.</p>', |
|
| 241 | - 'info_connexion_mysql' => 'La connessione a SQL', |
|
| 242 | - 'info_connexion_ok' => 'La connessione è riuscita.', |
|
| 243 | - 'info_contact' => 'Contatti', |
|
| 244 | - 'info_contenu_articles' => 'Contentuto degli articoli', |
|
| 245 | - 'info_creation_paragraphe' => 'Per creare dei paragrafi indipendenti, lasciare delle righe vuote.', # RELIRE |
|
| 246 | - 'info_creation_rubrique' => 'Prima di poter scrivere degli articoli, <br />devi creare almeno una rubrica.<br />', |
|
| 247 | - 'info_creation_tables' => 'Creazione delle tabelle nel database', |
|
| 248 | - 'info_creer_base' => '<b>Creare</b> un nuovo database:', |
|
| 249 | - 'info_dans_rubrique' => 'Nella rubrica:', |
|
| 250 | - 'info_date_publication_anterieure' => 'Data di redazione anteriore:', |
|
| 251 | - 'info_date_referencement' => 'DATA DI INSERIMENTO IN REPERTORIO DI QUESTO SITO:', |
|
| 252 | - 'info_derniere_etape' => 'Finito!', |
|
| 253 | - 'info_descriptif' => 'Descrizione:', |
|
| 254 | - 'info_desinstaller_plugin' => 'elimina i dati e disattiva il plug-in', |
|
| 255 | - 'info_discussion_cours' => 'Discussioni in corso', |
|
| 256 | - 'info_ecrire_article' => 'Prima di poter scrivere degli articoli, devi creare almeno una rubrica.', |
|
| 257 | - 'info_email_envoi' => 'Indirizzo email del mittente (opzionale)', |
|
| 258 | - 'info_email_envoi_txt' => 'Indicare qui l’indirizzo da utilizzare per l’invio degli email (come impostazione predefinita l’indirizzo del destinatario sarà utilizzato come indirizzo del mittente):', |
|
| 259 | - 'info_email_webmestre' => 'Indirizzo email della webmistress', # RELIRE |
|
| 260 | - 'info_envoi_email_automatique' => 'Invio di email automatico', |
|
| 261 | - 'info_envoyer_maintenant' => 'Invia adesso', |
|
| 262 | - 'info_etape_suivante' => 'Passare alla fase successiva', |
|
| 263 | - 'info_etape_suivante_1' => 'Puoi passare alla fase successiva.', |
|
| 264 | - 'info_etape_suivante_2' => 'Puoi passare alla fase successiva.', |
|
| 265 | - 'info_exportation_base' => 'esportazione del database verso @archive@', |
|
| 266 | - 'info_facilite_suivi_activite' => 'Al fine di facilitare il monitoraggio |
|
| 204 | + 'info_ajouter_rubrique' => 'Aggiungi un’altra rubrica da amministrare:', |
|
| 205 | + 'info_annonce_nouveautes' => 'Annuncio delle novità', |
|
| 206 | + 'info_article' => 'articolo', |
|
| 207 | + 'info_article_2' => 'articoli', |
|
| 208 | + 'info_article_a_paraitre' => 'Gli articoli postdatati da pubblicare', |
|
| 209 | + 'info_articles_02' => 'articoli', |
|
| 210 | + 'info_articles_2' => 'Articoli', |
|
| 211 | + 'info_articles_auteur' => 'Articoli di questo autore', |
|
| 212 | + 'info_articles_trouves' => 'Articoli trovati', |
|
| 213 | + 'info_attente_validation' => 'I tuoi articoli in attesa di convalida', |
|
| 214 | + 'info_aujourdhui' => 'oggi: ', |
|
| 215 | + 'info_auteurs' => 'Le autrici', |
|
| 216 | + 'info_auteurs_par_tri' => 'Autrici@partri@', |
|
| 217 | + 'info_auteurs_trouves' => 'Autrici trovate', |
|
| 218 | + 'info_authentification_externe' => 'Autenticazione esterna', |
|
| 219 | + 'info_avertissement' => 'Avvertimento', |
|
| 220 | + 'info_barre_outils' => 'con la barra degli strumenti?', |
|
| 221 | + 'info_base_installee' => 'La struttura del vostro database è installata.', |
|
| 222 | + 'info_chapeau' => 'Introduzione', |
|
| 223 | + 'info_chapeau_2' => 'Introduzione:', |
|
| 224 | + 'info_chemin_acces_1' => 'Opzioni: <b>Percorso d’accesso ai dati nell’elenco</b>', |
|
| 225 | + 'info_chemin_acces_2' => 'È necessario specificare il percorso per accedere ai dati nell’elenco. Questa informazione è indispensabile al fine di leggere i profili utente in esso contenuti.', |
|
| 226 | + 'info_chemin_acces_annuaire' => 'Opzioni: <b>Percorso d’accesso ai dati nell’elenco', |
|
| 227 | + 'info_choix_base' => 'Terza fase: ', |
|
| 228 | + 'info_classement_1' => '<sup>o</sup> su @liste@', |
|
| 229 | + 'info_classement_2' => '<sup>o</sup> su @liste@', |
|
| 230 | + 'info_code_acces' => 'Non dimenticare i tuoi codici d’accesso!', |
|
| 231 | + 'info_config_suivi' => 'Se questo indirizzo corrisponde a una mailing-list, è possibile indicare qui sotto l’indirizzo al quale i partecipanti del sito possono iscriversi. Questo indirizzo può essere una URL (per esempio la pagina di iscrizione via Web alla lista), oppure un indirizzo email che contiene un Oggetto specifico (per esempio: <tt>@adresse_suivi@?subject=subscribe</tt>):', |
|
| 232 | + 'info_config_suivi_explication' => 'È possibile abbonarsi alla mailing-list di questo sito. Verranno spedite per email le notifiche degli articoli e delle brevi proposte per la pubblicazione.', |
|
| 233 | + 'info_confirmer_passe' => 'Conferma la nuova password:', |
|
| 234 | + 'info_conflit_edition_avis_non_sauvegarde' => 'Attenzione, i campi seguenti sono già stati modificati. Quindi le vostre modifiche su questi campi non sono state registrate.', |
|
| 235 | + 'info_conflit_edition_differences' => 'Differenze:', |
|
| 236 | + 'info_conflit_edition_version_enregistree' => 'La versione registrata:', |
|
| 237 | + 'info_conflit_edition_votre_version' => 'La tua versione:', |
|
| 238 | + 'info_connexion_base' => 'Prova di connessione al database', |
|
| 239 | + 'info_connexion_base_donnee' => 'Connessione al proprio database', |
|
| 240 | + 'info_connexion_ldap_ok' => 'La connessione LDAP è riuscita.</b><p> È possibile passare alla fase successiva.</p>', |
|
| 241 | + 'info_connexion_mysql' => 'La connessione a SQL', |
|
| 242 | + 'info_connexion_ok' => 'La connessione è riuscita.', |
|
| 243 | + 'info_contact' => 'Contatti', |
|
| 244 | + 'info_contenu_articles' => 'Contentuto degli articoli', |
|
| 245 | + 'info_creation_paragraphe' => 'Per creare dei paragrafi indipendenti, lasciare delle righe vuote.', # RELIRE |
|
| 246 | + 'info_creation_rubrique' => 'Prima di poter scrivere degli articoli, <br />devi creare almeno una rubrica.<br />', |
|
| 247 | + 'info_creation_tables' => 'Creazione delle tabelle nel database', |
|
| 248 | + 'info_creer_base' => '<b>Creare</b> un nuovo database:', |
|
| 249 | + 'info_dans_rubrique' => 'Nella rubrica:', |
|
| 250 | + 'info_date_publication_anterieure' => 'Data di redazione anteriore:', |
|
| 251 | + 'info_date_referencement' => 'DATA DI INSERIMENTO IN REPERTORIO DI QUESTO SITO:', |
|
| 252 | + 'info_derniere_etape' => 'Finito!', |
|
| 253 | + 'info_descriptif' => 'Descrizione:', |
|
| 254 | + 'info_desinstaller_plugin' => 'elimina i dati e disattiva il plug-in', |
|
| 255 | + 'info_discussion_cours' => 'Discussioni in corso', |
|
| 256 | + 'info_ecrire_article' => 'Prima di poter scrivere degli articoli, devi creare almeno una rubrica.', |
|
| 257 | + 'info_email_envoi' => 'Indirizzo email del mittente (opzionale)', |
|
| 258 | + 'info_email_envoi_txt' => 'Indicare qui l’indirizzo da utilizzare per l’invio degli email (come impostazione predefinita l’indirizzo del destinatario sarà utilizzato come indirizzo del mittente):', |
|
| 259 | + 'info_email_webmestre' => 'Indirizzo email della webmistress', # RELIRE |
|
| 260 | + 'info_envoi_email_automatique' => 'Invio di email automatico', |
|
| 261 | + 'info_envoyer_maintenant' => 'Invia adesso', |
|
| 262 | + 'info_etape_suivante' => 'Passare alla fase successiva', |
|
| 263 | + 'info_etape_suivante_1' => 'Puoi passare alla fase successiva.', |
|
| 264 | + 'info_etape_suivante_2' => 'Puoi passare alla fase successiva.', |
|
| 265 | + 'info_exportation_base' => 'esportazione del database verso @archive@', |
|
| 266 | + 'info_facilite_suivi_activite' => 'Al fine di facilitare il monitoraggio |
|
| 267 | 267 | dell’attività editoriale del sito, SPIP può far pervenire via email, |
| 268 | 268 | per esempio ad una mailing-list delle redattrici, l’annuncio delle domande di |
| 269 | 269 | pubblicazione e di convalida degli articoli.', |
| 270 | - 'info_fichiers_authent' => 'File d’autenticazione ".htpasswd"', |
|
| 271 | - 'info_forums_abo_invites' => 'Il sito comprende dei forum accessibili solo a utenti registrate. Nel sito pubblico è quindi presente una pagina d’iscrizione.', |
|
| 272 | - 'info_gauche_admin_tech' => '<b>Questa pagina è accessibile solo alle responsabili del sito.</b><p> Permette l’accesso alle diverse funzioni di manutenzione tecnica. Alcune di esse richiedono una procedura di identificazione specifica, tramite accesso FTP.</p>', # RELIRE |
|
| 273 | - 'info_gauche_admin_vider' => '<b>Questa pagina è accessibile solo alle responsabili del sito.</b><p> Permette l’accesso alle diverse funzioni di manutenzione tecnica. Alcune di esse richiedono una procedura di identificazione specifica, tramite accesso FTP.</p>', # RELIRE |
|
| 274 | - 'info_gauche_auteurs' => 'Elenco di tutte le autrici del sito. |
|
| 270 | + 'info_fichiers_authent' => 'File d’autenticazione ".htpasswd"', |
|
| 271 | + 'info_forums_abo_invites' => 'Il sito comprende dei forum accessibili solo a utenti registrate. Nel sito pubblico è quindi presente una pagina d’iscrizione.', |
|
| 272 | + 'info_gauche_admin_tech' => '<b>Questa pagina è accessibile solo alle responsabili del sito.</b><p> Permette l’accesso alle diverse funzioni di manutenzione tecnica. Alcune di esse richiedono una procedura di identificazione specifica, tramite accesso FTP.</p>', # RELIRE |
|
| 273 | + 'info_gauche_admin_vider' => '<b>Questa pagina è accessibile solo alle responsabili del sito.</b><p> Permette l’accesso alle diverse funzioni di manutenzione tecnica. Alcune di esse richiedono una procedura di identificazione specifica, tramite accesso FTP.</p>', # RELIRE |
|
| 274 | + 'info_gauche_auteurs' => 'Elenco di tutte le autrici del sito. |
|
| 275 | 275 | Il loro status è indicato dal colore dell’icona (redattrice = giallo; amministratrice = verde).', |
| 276 | - 'info_gauche_auteurs_exterieurs' => 'Le autrici esterne, senza accesso al sito, sono indicate da un’icona blu; |
|
| 276 | + 'info_gauche_auteurs_exterieurs' => 'Le autrici esterne, senza accesso al sito, sono indicate da un’icona blu; |
|
| 277 | 277 | le autrici eliminate sono indicate da un’icona grigia.', # RELIRE |
| 278 | - 'info_gauche_messagerie' => 'Il sistema di messaggistica permette di scambiare dei messaggi tra redattrici, di conservare dei memo (promemoria ad uso personale) o di pubblicare degli annunci nel pannello di controllo dell’area riservata (se sei amministratrice).', |
|
| 279 | - 'info_gauche_statistiques_referers' => 'Questa pagina presenta un elenco dei siti che contengono link verso il tuo (<i>referrer</i>). Questo elenco è valido però solo per oggi essendo azzerato ogni 24 ore.', |
|
| 280 | - 'info_gauche_visiteurs_enregistres' => 'Trovi qui i visitatori registrati allo spazio |
|
| 278 | + 'info_gauche_messagerie' => 'Il sistema di messaggistica permette di scambiare dei messaggi tra redattrici, di conservare dei memo (promemoria ad uso personale) o di pubblicare degli annunci nel pannello di controllo dell’area riservata (se sei amministratrice).', |
|
| 279 | + 'info_gauche_statistiques_referers' => 'Questa pagina presenta un elenco dei siti che contengono link verso il tuo (<i>referrer</i>). Questo elenco è valido però solo per oggi essendo azzerato ogni 24 ore.', |
|
| 280 | + 'info_gauche_visiteurs_enregistres' => 'Trovi qui i visitatori registrati allo spazio |
|
| 281 | 281 | pubblico del sito (forum su abbonamento).', |
| 282 | - 'info_generation_miniatures_images' => 'Generazione di thumbnail di immagini', |
|
| 283 | - 'info_hebergeur_desactiver_envoi_email' => 'Alcuni hoster disattivano l’invio automatico di email |
|
| 282 | + 'info_generation_miniatures_images' => 'Generazione di thumbnail di immagini', |
|
| 283 | + 'info_hebergeur_desactiver_envoi_email' => 'Alcuni hoster disattivano l’invio automatico di email |
|
| 284 | 284 | dai loro server. In questo caso, le funzionalità di SPIP di seguito riportate non funzioneranno.', |
| 285 | - 'info_hier' => 'ieri:', |
|
| 286 | - 'info_identification_publique' => 'La tua identità pubblica...', |
|
| 287 | - 'info_image_process' => 'Seleziona il metodo migliore per la creazione delle anteprime cliccando sull’immagine corrispondente.', |
|
| 288 | - 'info_image_process2' => 'Se non appare alcuna immagine, ciò significa che la configurazione del server non permette l’uso di tali funzioni. Se si desidera utilizzarle, contattate la responsabile tecnica chiedendo delle estensioni "GD" o "Imagick".', # RELIRE |
|
| 289 | - 'info_images_auto' => 'Immagini elaborate automaticamente', |
|
| 290 | - 'info_informations_personnelles' => 'Informazioni personali', |
|
| 291 | - 'info_inscription_automatique' => 'Iscrizione automatica di nuove redattrici', |
|
| 292 | - 'info_jeu_caractere' => 'Set di caratteri del sito', |
|
| 293 | - 'info_jours' => 'giorni', |
|
| 294 | - 'info_laisser_champs_vides' => 'lasciare questi campi vuoti)', |
|
| 295 | - 'info_langues' => 'Lingua del sito', |
|
| 296 | - 'info_ldap_ok' => 'L’autenticazione LDAP è installata.', |
|
| 297 | - 'info_lien_hypertexte' => 'Link ipertestuale:', |
|
| 298 | - 'info_liste_redacteurs_connectes' => 'Elenco delle redattrici collegate', |
|
| 299 | - 'info_login_existant' => 'Questo login esiste già.', |
|
| 300 | - 'info_login_trop_court' => 'Login troppo corto.', |
|
| 301 | - 'info_logos' => 'I logo', |
|
| 302 | - 'info_maximum' => 'massimo:', |
|
| 303 | - 'info_meme_rubrique' => 'Nella stessa rubrica', |
|
| 304 | - 'info_message_en_redaction' => 'I tuoi messaggi in corso di redazione', |
|
| 305 | - 'info_message_technique' => 'Messaggio tecnico:', |
|
| 306 | - 'info_messagerie_interne' => 'Sistema di messaggistica interna', |
|
| 307 | - 'info_mise_a_niveau_base' => 'aggiornamento del database SQL', |
|
| 308 | - 'info_mise_a_niveau_base_2' => '{{Attenzione!}} È stata installata una versione |
|
| 285 | + 'info_hier' => 'ieri:', |
|
| 286 | + 'info_identification_publique' => 'La tua identità pubblica...', |
|
| 287 | + 'info_image_process' => 'Seleziona il metodo migliore per la creazione delle anteprime cliccando sull’immagine corrispondente.', |
|
| 288 | + 'info_image_process2' => 'Se non appare alcuna immagine, ciò significa che la configurazione del server non permette l’uso di tali funzioni. Se si desidera utilizzarle, contattate la responsabile tecnica chiedendo delle estensioni "GD" o "Imagick".', # RELIRE |
|
| 289 | + 'info_images_auto' => 'Immagini elaborate automaticamente', |
|
| 290 | + 'info_informations_personnelles' => 'Informazioni personali', |
|
| 291 | + 'info_inscription_automatique' => 'Iscrizione automatica di nuove redattrici', |
|
| 292 | + 'info_jeu_caractere' => 'Set di caratteri del sito', |
|
| 293 | + 'info_jours' => 'giorni', |
|
| 294 | + 'info_laisser_champs_vides' => 'lasciare questi campi vuoti)', |
|
| 295 | + 'info_langues' => 'Lingua del sito', |
|
| 296 | + 'info_ldap_ok' => 'L’autenticazione LDAP è installata.', |
|
| 297 | + 'info_lien_hypertexte' => 'Link ipertestuale:', |
|
| 298 | + 'info_liste_redacteurs_connectes' => 'Elenco delle redattrici collegate', |
|
| 299 | + 'info_login_existant' => 'Questo login esiste già.', |
|
| 300 | + 'info_login_trop_court' => 'Login troppo corto.', |
|
| 301 | + 'info_logos' => 'I logo', |
|
| 302 | + 'info_maximum' => 'massimo:', |
|
| 303 | + 'info_meme_rubrique' => 'Nella stessa rubrica', |
|
| 304 | + 'info_message_en_redaction' => 'I tuoi messaggi in corso di redazione', |
|
| 305 | + 'info_message_technique' => 'Messaggio tecnico:', |
|
| 306 | + 'info_messagerie_interne' => 'Sistema di messaggistica interna', |
|
| 307 | + 'info_mise_a_niveau_base' => 'aggiornamento del database SQL', |
|
| 308 | + 'info_mise_a_niveau_base_2' => '{{Attenzione!}} È stata installata una versione |
|
| 309 | 309 | dei file di SPIP {precedente} rispetto a quella che era in uso per questo sito: |
| 310 | 310 | le informazioni contenute nel database sono probabilmente andate perse.<br />{{Reinstallare i file di SPIP.}}', |
| 311 | - 'info_modifier_auteur' => 'Modifica l’autrice:', |
|
| 312 | - 'info_modifier_rubrique' => 'Modifica la rubrica:', |
|
| 313 | - 'info_modifier_titre' => 'Modifica: @titre@', |
|
| 314 | - 'info_mon_site_spip' => 'Il mio sito SPIP', |
|
| 315 | - 'info_moyenne' => 'media: ', |
|
| 316 | - 'info_multi_cet_article' => 'Lingua di questo articolo:', |
|
| 317 | - 'info_multi_langues_choisies' => 'Selezionare di seguito le lingue disponibili per le redattrici del sito. |
|
| 311 | + 'info_modifier_auteur' => 'Modifica l’autrice:', |
|
| 312 | + 'info_modifier_rubrique' => 'Modifica la rubrica:', |
|
| 313 | + 'info_modifier_titre' => 'Modifica: @titre@', |
|
| 314 | + 'info_mon_site_spip' => 'Il mio sito SPIP', |
|
| 315 | + 'info_moyenne' => 'media: ', |
|
| 316 | + 'info_multi_cet_article' => 'Lingua di questo articolo:', |
|
| 317 | + 'info_multi_langues_choisies' => 'Selezionare di seguito le lingue disponibili per le redattrici del sito. |
|
| 318 | 318 | Le lingue già utilizzate nel sito (visualizzate per prime) non possono essere disattivate.', |
| 319 | - 'info_multi_secteurs' => '... solo per le rubriche collocate nella {root} del sito?', |
|
| 320 | - 'info_nom' => 'Nome', |
|
| 321 | - 'info_nom_destinataire' => 'Nome del destinatario', |
|
| 322 | - 'info_nom_site' => 'Nome del tuo sito', |
|
| 323 | - 'info_nombre_articles' => '@nb_articles@ articoli,', |
|
| 324 | - 'info_nombre_rubriques' => '@nb_rubriques@ rubriche,', |
|
| 325 | - 'info_nombre_sites' => '@nb_sites@ siti, ', |
|
| 326 | - 'info_non_deplacer' => 'Non spostare...', |
|
| 327 | - 'info_non_envoi_annonce_dernieres_nouveautes' => 'SPIP può inviare regolarmente annunci sulle ultime novità del sito |
|
| 319 | + 'info_multi_secteurs' => '... solo per le rubriche collocate nella {root} del sito?', |
|
| 320 | + 'info_nom' => 'Nome', |
|
| 321 | + 'info_nom_destinataire' => 'Nome del destinatario', |
|
| 322 | + 'info_nom_site' => 'Nome del tuo sito', |
|
| 323 | + 'info_nombre_articles' => '@nb_articles@ articoli,', |
|
| 324 | + 'info_nombre_rubriques' => '@nb_rubriques@ rubriche,', |
|
| 325 | + 'info_nombre_sites' => '@nb_sites@ siti, ', |
|
| 326 | + 'info_non_deplacer' => 'Non spostare...', |
|
| 327 | + 'info_non_envoi_annonce_dernieres_nouveautes' => 'SPIP può inviare regolarmente annunci sulle ultime novità del sito |
|
| 328 | 328 | (articoli e brevi recentemente pubblicati).', |
| 329 | - 'info_non_envoi_liste_nouveautes' => 'Non inviare l’elenco delle novità', |
|
| 330 | - 'info_non_modifiable' => 'non può essere modificato', |
|
| 331 | - 'info_non_suppression_mot_cle' => 'non voglio cancellare questa parola chiave.', |
|
| 332 | - 'info_notes' => 'Note', |
|
| 333 | - 'info_nouvel_article' => 'Nuovo articolo', |
|
| 334 | - 'info_nouvelle_traduction' => 'Nuova traduzione:', |
|
| 335 | - 'info_numero_article' => 'ARTICOLO NUMERO:', |
|
| 336 | - 'info_obligatoire_02' => '(obbligatorio)', # MODIF |
|
| 337 | - 'info_option_accepter_visiteurs' => 'Accetta l’iscrizione di utenti del sito pubblico', |
|
| 338 | - 'info_option_ne_pas_accepter_visiteurs' => 'Rifiuta l’iscrizione di utenti', |
|
| 339 | - 'info_options_avancees' => 'OPZIONE AVANZATA', |
|
| 340 | - 'info_ou' => 'o... ', |
|
| 341 | - 'info_page_interdite' => 'Pagina riservata', |
|
| 342 | - 'info_par_nom' => 'per nome', |
|
| 343 | - 'info_par_nombre_article' => 'per numero di articoli', |
|
| 344 | - 'info_par_statut' => 'per status', |
|
| 345 | - 'info_par_tri' => '’(per @tri@)’', |
|
| 346 | - 'info_passe_trop_court' => 'Password troppo corta.', |
|
| 347 | - 'info_passes_identiques' => 'Le due password non sono uguali.', |
|
| 348 | - 'info_plus_cinq_car' => 'più di 5 caratteri', |
|
| 349 | - 'info_plus_cinq_car_2' => '(Più di 5 caratteri)', |
|
| 350 | - 'info_plus_trois_car' => '(Più di 3 caratteri)', |
|
| 351 | - 'info_popularite' => 'popolarità: @popularite@; visite: @visites@', |
|
| 352 | - 'info_post_scriptum' => 'Post Scriptum', |
|
| 353 | - 'info_post_scriptum_2' => 'Post Scriptum:', |
|
| 354 | - 'info_pour' => 'per', |
|
| 355 | - 'info_preview_texte' => 'È possibile visualizzare un’anteprima del sito comprendente anche gli articoli e le brevi "proposti" per la pubblicazione. Questa funzionalità può essere disattivata, consentita solo alle amministratrici o a tutte le redattrici.', # MODIF |
|
| 356 | - 'info_procedez_par_etape' => 'procedere passo dopo passo', |
|
| 357 | - 'info_procedure_maj_version' => 'è necessario avviare la procedura di aggiornamento per adattare |
|
| 329 | + 'info_non_envoi_liste_nouveautes' => 'Non inviare l’elenco delle novità', |
|
| 330 | + 'info_non_modifiable' => 'non può essere modificato', |
|
| 331 | + 'info_non_suppression_mot_cle' => 'non voglio cancellare questa parola chiave.', |
|
| 332 | + 'info_notes' => 'Note', |
|
| 333 | + 'info_nouvel_article' => 'Nuovo articolo', |
|
| 334 | + 'info_nouvelle_traduction' => 'Nuova traduzione:', |
|
| 335 | + 'info_numero_article' => 'ARTICOLO NUMERO:', |
|
| 336 | + 'info_obligatoire_02' => '(obbligatorio)', # MODIF |
|
| 337 | + 'info_option_accepter_visiteurs' => 'Accetta l’iscrizione di utenti del sito pubblico', |
|
| 338 | + 'info_option_ne_pas_accepter_visiteurs' => 'Rifiuta l’iscrizione di utenti', |
|
| 339 | + 'info_options_avancees' => 'OPZIONE AVANZATA', |
|
| 340 | + 'info_ou' => 'o... ', |
|
| 341 | + 'info_page_interdite' => 'Pagina riservata', |
|
| 342 | + 'info_par_nom' => 'per nome', |
|
| 343 | + 'info_par_nombre_article' => 'per numero di articoli', |
|
| 344 | + 'info_par_statut' => 'per status', |
|
| 345 | + 'info_par_tri' => '’(per @tri@)’', |
|
| 346 | + 'info_passe_trop_court' => 'Password troppo corta.', |
|
| 347 | + 'info_passes_identiques' => 'Le due password non sono uguali.', |
|
| 348 | + 'info_plus_cinq_car' => 'più di 5 caratteri', |
|
| 349 | + 'info_plus_cinq_car_2' => '(Più di 5 caratteri)', |
|
| 350 | + 'info_plus_trois_car' => '(Più di 3 caratteri)', |
|
| 351 | + 'info_popularite' => 'popolarità: @popularite@; visite: @visites@', |
|
| 352 | + 'info_post_scriptum' => 'Post Scriptum', |
|
| 353 | + 'info_post_scriptum_2' => 'Post Scriptum:', |
|
| 354 | + 'info_pour' => 'per', |
|
| 355 | + 'info_preview_texte' => 'È possibile visualizzare un’anteprima del sito comprendente anche gli articoli e le brevi "proposti" per la pubblicazione. Questa funzionalità può essere disattivata, consentita solo alle amministratrici o a tutte le redattrici.', # MODIF |
|
| 356 | + 'info_procedez_par_etape' => 'procedere passo dopo passo', |
|
| 357 | + 'info_procedure_maj_version' => 'è necessario avviare la procedura di aggiornamento per adattare |
|
| 358 | 358 | il database alla nuova versione di SPIP.', |
| 359 | - 'info_proxy_ok' => 'Test del proxy riuscito.', |
|
| 360 | - 'info_ps' => 'P.S.', |
|
| 361 | - 'info_publier' => 'pubblicare', |
|
| 362 | - 'info_publies' => 'I tuoi articoli pubblicati', |
|
| 363 | - 'info_question_accepter_visiteurs' => 'I modelli di pagina del sito prevedono la registrazione di utenti senza accesso all’area riservata. Attivare la seguente funzionalità:', |
|
| 364 | - 'info_question_inscription_nouveaux_redacteurs' => 'Accettate le iscrizioni di nuove redattrici |
|
| 359 | + 'info_proxy_ok' => 'Test del proxy riuscito.', |
|
| 360 | + 'info_ps' => 'P.S.', |
|
| 361 | + 'info_publier' => 'pubblicare', |
|
| 362 | + 'info_publies' => 'I tuoi articoli pubblicati', |
|
| 363 | + 'info_question_accepter_visiteurs' => 'I modelli di pagina del sito prevedono la registrazione di utenti senza accesso all’area riservata. Attivare la seguente funzionalità:', |
|
| 364 | + 'info_question_inscription_nouveaux_redacteurs' => 'Accettate le iscrizioni di nuove redattrici |
|
| 365 | 365 | direttamente dal sito pubblico? In questo caso, chi visita il sito potrà iscriversi |
| 366 | 366 | grazie ad un modulo automatizzato e potrà accedere all’area riservata per proporre i propri articoli. |
| 367 | 367 | <div class="notice">Durante la fase d’iscrizione, |
@@ -370,317 +370,317 @@ discard block |
||
| 370 | 370 | host disattivano l’invio di email dai |
| 371 | 371 | propri server: in questo caso, l’iscrizione automatica è |
| 372 | 372 | impossibile.', # RELIRE |
| 373 | - 'info_qui_edite' => '@nom_auteur_modif@ ha lavorato su questo contenuto @date_diff@ minuti fa', |
|
| 374 | - 'info_racine_site' => 'Root del sito', |
|
| 375 | - 'info_recharger_page' => 'Aggiorna questa pagina fra qualche istante.', |
|
| 376 | - 'info_recherche_auteur_zero' => 'Nessun risultato per "@cherche_auteur@".', |
|
| 377 | - 'info_recommencer' => 'Ricomincia.', |
|
| 378 | - 'info_redacteur_1' => 'Redattori', |
|
| 379 | - 'info_redacteur_2' => 'avendo accesso allo spazio privato (<i>raccommandato</i>)', |
|
| 380 | - 'info_redacteurs' => 'Redattrici', |
|
| 381 | - 'info_redaction_en_cours' => 'IN CORSO DI REDAZIONE', |
|
| 382 | - 'info_redirection' => 'Reindirizzamento', |
|
| 383 | - 'info_refuses' => 'I tuoi articoli rifiutati', |
|
| 384 | - 'info_reglage_ldap' => 'Opzioni: <b>Parametri per l’importazione LDAP</b>', |
|
| 385 | - 'info_renvoi_article' => '<b>Reindirizzamento.</b> Quest’articolo rimanda alla pagina:', |
|
| 386 | - 'info_reserve_admin' => 'Solo le amministratrici possono modificare quest’indirizzo.', |
|
| 387 | - 'info_restreindre_rubrique' => 'Limita la facoltà di gestione alla rubrica:', |
|
| 388 | - 'info_resultat_recherche' => 'Risultati della ricerca:', |
|
| 389 | - 'info_rubriques' => 'Rubriche', |
|
| 390 | - 'info_rubriques_02' => 'rubriche', |
|
| 391 | - 'info_rubriques_trouvees' => 'Rubriche trovate', |
|
| 392 | - 'info_sans_titre' => 'Senza titolo', |
|
| 393 | - 'info_selection_chemin_acces' => '<b>Seleziona</b> qui sotto il percorso d’accesso nell’elenco:', |
|
| 394 | - 'info_signatures' => 'firme', |
|
| 395 | - 'info_site' => 'Sito', |
|
| 396 | - 'info_site_2' => 'sito: ', |
|
| 397 | - 'info_site_min' => 'sito', |
|
| 398 | - 'info_site_reference_2' => 'Sito repertoriato', |
|
| 399 | - 'info_site_web' => 'Sito Web :', |
|
| 400 | - 'info_sites' => 'siti', |
|
| 401 | - 'info_sites_lies_mot' => 'I siti in repertorio legati a questa parola chiave', |
|
| 402 | - 'info_sites_proxy' => 'Utilizza un proxy', |
|
| 403 | - 'info_sites_trouves' => 'Siti trovati', |
|
| 404 | - 'info_sous_titre' => 'Sottotitolo:', |
|
| 405 | - 'info_statut_administrateur' => 'Amministratrice', |
|
| 406 | - 'info_statut_auteur' => 'Status di questa autrice:', |
|
| 407 | - 'info_statut_auteur_a_confirmer' => 'Iscrizione da confermare', |
|
| 408 | - 'info_statut_auteur_autre' => 'Altro stato:', |
|
| 409 | - 'info_statut_redacteur' => 'Redattrice', |
|
| 410 | - 'info_statut_utilisateurs_1' => 'Status predefinito delle utenti importate', |
|
| 411 | - 'info_statut_utilisateurs_2' => 'Scegli lo status da attribuire alle personne presenti nell’elenco LDAP quando si collegano per la prima volta. Potrai poi modificare questa impostazione per ogni singola autrice.', |
|
| 412 | - 'info_suivi_activite' => 'Monitoraggio dell’attività editoriale', |
|
| 413 | - 'info_surtitre' => 'Occhiello:', |
|
| 414 | - 'info_syndication_integrale_1' => 'Il tuo sito propone dei file di syndication (vedi « <a href="@url@">@titre@</a> »).', |
|
| 415 | - 'info_syndication_integrale_2' => 'Si desidera trasmettere gli articoli in versione integrale oppure in versione riassunta di un centinaio di caratteri?', |
|
| 416 | - 'info_table_prefix' => 'È possibile modificare il prefisso del nome delle tabelle del database (cosa indispensabile se si desidera installare più siti usando il medesimo database). Questo prefisso si deve scrivere usando esclusivamente lettere minuscole, prive di accenti e senza alcuno spazio.', |
|
| 417 | - 'info_taille_maximale_images' => 'SPIP testerà la dimensione massima delle immagini che può manipolare (in milioni di pixel).<br /> Le immagini di dimensione maggiore non saranno ridotte.', |
|
| 418 | - 'info_taille_maximale_vignette' => 'Dimensione massima delle immagini create dal sistema:', |
|
| 419 | - 'info_terminer_installation' => 'Puoi ora terminare la procedura d’installazione standard.', |
|
| 420 | - 'info_texte' => 'Testo', |
|
| 421 | - 'info_texte_explicatif' => 'Testo esplicativo', |
|
| 422 | - 'info_texte_long' => '(il testo è lungo: è quindi visualizzato in più sezioni che verranno riunificate dopo la convalida)', |
|
| 423 | - 'info_texte_message' => 'Testo del messaggio', |
|
| 424 | - 'info_texte_message_02' => 'Testo del messaggio', |
|
| 425 | - 'info_titre' => 'Titolo:', |
|
| 426 | - 'info_total' => 'totale: ', |
|
| 427 | - 'info_tous_articles_en_redaction' => 'Tutti gli articoli in corso di redazione', |
|
| 428 | - 'info_tous_articles_presents' => 'Tutti gli articoli pubblicati in questa rubrica', |
|
| 429 | - 'info_tous_les' => 'tutti i:', |
|
| 430 | - 'info_tout_site' => 'Tutto il sito', |
|
| 431 | - 'info_tout_site2' => 'L’articolo non è stato tradotto in questa lingua.', |
|
| 432 | - 'info_tout_site3' => 'L’articolo è stato tradotto in questa lingua, ma sono state effettuate alcune modifiche all’articolo di riferimento. La traduzione deve quindi essere aggiornata.', |
|
| 433 | - 'info_tout_site4' => 'L’articolo è stato tradotto in questa lingua e la traduzione è aggiornata.', |
|
| 434 | - 'info_tout_site5' => 'Articolo originale.', |
|
| 435 | - 'info_tout_site6' => '<b>Attenzione:</b> solo gli articoli originali vengono visualizzati. |
|
| 373 | + 'info_qui_edite' => '@nom_auteur_modif@ ha lavorato su questo contenuto @date_diff@ minuti fa', |
|
| 374 | + 'info_racine_site' => 'Root del sito', |
|
| 375 | + 'info_recharger_page' => 'Aggiorna questa pagina fra qualche istante.', |
|
| 376 | + 'info_recherche_auteur_zero' => 'Nessun risultato per "@cherche_auteur@".', |
|
| 377 | + 'info_recommencer' => 'Ricomincia.', |
|
| 378 | + 'info_redacteur_1' => 'Redattori', |
|
| 379 | + 'info_redacteur_2' => 'avendo accesso allo spazio privato (<i>raccommandato</i>)', |
|
| 380 | + 'info_redacteurs' => 'Redattrici', |
|
| 381 | + 'info_redaction_en_cours' => 'IN CORSO DI REDAZIONE', |
|
| 382 | + 'info_redirection' => 'Reindirizzamento', |
|
| 383 | + 'info_refuses' => 'I tuoi articoli rifiutati', |
|
| 384 | + 'info_reglage_ldap' => 'Opzioni: <b>Parametri per l’importazione LDAP</b>', |
|
| 385 | + 'info_renvoi_article' => '<b>Reindirizzamento.</b> Quest’articolo rimanda alla pagina:', |
|
| 386 | + 'info_reserve_admin' => 'Solo le amministratrici possono modificare quest’indirizzo.', |
|
| 387 | + 'info_restreindre_rubrique' => 'Limita la facoltà di gestione alla rubrica:', |
|
| 388 | + 'info_resultat_recherche' => 'Risultati della ricerca:', |
|
| 389 | + 'info_rubriques' => 'Rubriche', |
|
| 390 | + 'info_rubriques_02' => 'rubriche', |
|
| 391 | + 'info_rubriques_trouvees' => 'Rubriche trovate', |
|
| 392 | + 'info_sans_titre' => 'Senza titolo', |
|
| 393 | + 'info_selection_chemin_acces' => '<b>Seleziona</b> qui sotto il percorso d’accesso nell’elenco:', |
|
| 394 | + 'info_signatures' => 'firme', |
|
| 395 | + 'info_site' => 'Sito', |
|
| 396 | + 'info_site_2' => 'sito: ', |
|
| 397 | + 'info_site_min' => 'sito', |
|
| 398 | + 'info_site_reference_2' => 'Sito repertoriato', |
|
| 399 | + 'info_site_web' => 'Sito Web :', |
|
| 400 | + 'info_sites' => 'siti', |
|
| 401 | + 'info_sites_lies_mot' => 'I siti in repertorio legati a questa parola chiave', |
|
| 402 | + 'info_sites_proxy' => 'Utilizza un proxy', |
|
| 403 | + 'info_sites_trouves' => 'Siti trovati', |
|
| 404 | + 'info_sous_titre' => 'Sottotitolo:', |
|
| 405 | + 'info_statut_administrateur' => 'Amministratrice', |
|
| 406 | + 'info_statut_auteur' => 'Status di questa autrice:', |
|
| 407 | + 'info_statut_auteur_a_confirmer' => 'Iscrizione da confermare', |
|
| 408 | + 'info_statut_auteur_autre' => 'Altro stato:', |
|
| 409 | + 'info_statut_redacteur' => 'Redattrice', |
|
| 410 | + 'info_statut_utilisateurs_1' => 'Status predefinito delle utenti importate', |
|
| 411 | + 'info_statut_utilisateurs_2' => 'Scegli lo status da attribuire alle personne presenti nell’elenco LDAP quando si collegano per la prima volta. Potrai poi modificare questa impostazione per ogni singola autrice.', |
|
| 412 | + 'info_suivi_activite' => 'Monitoraggio dell’attività editoriale', |
|
| 413 | + 'info_surtitre' => 'Occhiello:', |
|
| 414 | + 'info_syndication_integrale_1' => 'Il tuo sito propone dei file di syndication (vedi « <a href="@url@">@titre@</a> »).', |
|
| 415 | + 'info_syndication_integrale_2' => 'Si desidera trasmettere gli articoli in versione integrale oppure in versione riassunta di un centinaio di caratteri?', |
|
| 416 | + 'info_table_prefix' => 'È possibile modificare il prefisso del nome delle tabelle del database (cosa indispensabile se si desidera installare più siti usando il medesimo database). Questo prefisso si deve scrivere usando esclusivamente lettere minuscole, prive di accenti e senza alcuno spazio.', |
|
| 417 | + 'info_taille_maximale_images' => 'SPIP testerà la dimensione massima delle immagini che può manipolare (in milioni di pixel).<br /> Le immagini di dimensione maggiore non saranno ridotte.', |
|
| 418 | + 'info_taille_maximale_vignette' => 'Dimensione massima delle immagini create dal sistema:', |
|
| 419 | + 'info_terminer_installation' => 'Puoi ora terminare la procedura d’installazione standard.', |
|
| 420 | + 'info_texte' => 'Testo', |
|
| 421 | + 'info_texte_explicatif' => 'Testo esplicativo', |
|
| 422 | + 'info_texte_long' => '(il testo è lungo: è quindi visualizzato in più sezioni che verranno riunificate dopo la convalida)', |
|
| 423 | + 'info_texte_message' => 'Testo del messaggio', |
|
| 424 | + 'info_texte_message_02' => 'Testo del messaggio', |
|
| 425 | + 'info_titre' => 'Titolo:', |
|
| 426 | + 'info_total' => 'totale: ', |
|
| 427 | + 'info_tous_articles_en_redaction' => 'Tutti gli articoli in corso di redazione', |
|
| 428 | + 'info_tous_articles_presents' => 'Tutti gli articoli pubblicati in questa rubrica', |
|
| 429 | + 'info_tous_les' => 'tutti i:', |
|
| 430 | + 'info_tout_site' => 'Tutto il sito', |
|
| 431 | + 'info_tout_site2' => 'L’articolo non è stato tradotto in questa lingua.', |
|
| 432 | + 'info_tout_site3' => 'L’articolo è stato tradotto in questa lingua, ma sono state effettuate alcune modifiche all’articolo di riferimento. La traduzione deve quindi essere aggiornata.', |
|
| 433 | + 'info_tout_site4' => 'L’articolo è stato tradotto in questa lingua e la traduzione è aggiornata.', |
|
| 434 | + 'info_tout_site5' => 'Articolo originale.', |
|
| 435 | + 'info_tout_site6' => '<b>Attenzione:</b> solo gli articoli originali vengono visualizzati. |
|
| 436 | 436 | Le traduzioni sono associate all’originale, |
| 437 | 437 | in un colore che indica il loro stato:', |
| 438 | - 'info_travail_colaboratif' => 'Lavoro di collaborazione sugli articoli', |
|
| 439 | - 'info_un_article' => 'un articolo, ', |
|
| 440 | - 'info_un_site' => 'un sito, ', |
|
| 441 | - 'info_une_rubrique' => 'una rubrica, ', |
|
| 442 | - 'info_une_rubrique_02' => '1 rubrica', |
|
| 443 | - 'info_url' => 'URL:', |
|
| 444 | - 'info_urlref' => 'Link ipertestuale:', |
|
| 445 | - 'info_utilisation_spip' => 'Puoi ora cominciare ad utilizzare il sistema di pubblicazione assistita...', |
|
| 446 | - 'info_visites_par_mois' => 'Visualizzazione per mese:', |
|
| 447 | - 'info_visiteur_1' => 'Visitatori', |
|
| 448 | - 'info_visiteur_2' => 'del sito pubblico', |
|
| 449 | - 'info_visiteurs' => 'Visitatori', |
|
| 450 | - 'info_visiteurs_02' => 'Visitatori del sito pubblico', |
|
| 451 | - 'install_adresse_base_hebergeur' => 'Indirizzo del database attribuito dal provider', |
|
| 452 | - 'install_echec_annonce' => 'L’installazione potrebbe fallire oppure causare problemi di funzionalità al sito...', |
|
| 453 | - 'install_extension_mbstring' => 'SPIP non funziona con:', |
|
| 454 | - 'install_extension_php_obligatoire' => 'SPIP esige l’estensione php:', |
|
| 455 | - 'install_login_base_hebergeur' => 'Login di connessione attribuito dal provider', |
|
| 456 | - 'install_nom_base_hebergeur' => 'Nome del database attribuito dal provider:', |
|
| 457 | - 'install_pas_table' => 'Database attualmente senza tabelle', |
|
| 458 | - 'install_pass_base_hebergeur' => 'Password di connessione attribuito dal provider', |
|
| 459 | - 'install_php_version' => 'PHP versione @version@ insufficiente (minimo = @minimum@)', |
|
| 460 | - 'install_select_langue' => 'Seleziona una lingua e poi clicca sul bottone « Avanti » per lanciare la procedura di installazione.', |
|
| 461 | - 'install_select_type_db' => 'Indicare il tipo di database:', |
|
| 462 | - 'install_select_type_mysql' => 'MySQL', |
|
| 463 | - 'install_select_type_sqlite2' => 'SQLite 2', |
|
| 464 | - 'install_select_type_sqlite3' => 'SQLite 3', |
|
| 465 | - 'install_serveur_hebergeur' => 'Server del database attribuito dall’hoster', |
|
| 466 | - 'install_table_prefix_hebergeur' => 'Prefisso della tabella attribuito dal provider:', |
|
| 467 | - 'install_tables_base' => 'Tabelle del database', |
|
| 468 | - 'install_types_db_connus' => 'SPIP può utilizzare <b>MySQL</b> (il più diffuso) e <b>SQLite</b>.', |
|
| 469 | - 'install_types_db_connus_avertissement' => 'Il supporto <b>PostgreSQL</b> viene proposto a titolo sperimentale', # RELIRE |
|
| 470 | - 'intem_redacteur' => 'redattrice', |
|
| 471 | - 'intitule_licence' => 'Licenza', |
|
| 472 | - 'item_accepter_inscriptions' => 'Accetta le iscrizioni', |
|
| 473 | - 'item_activer_messages_avertissement' => 'Attiva i messaggi d’avvertimento', |
|
| 474 | - 'item_administrateur_2' => 'amministratrice', |
|
| 475 | - 'item_afficher_calendrier' => 'Pubblica nel calendario', |
|
| 476 | - 'item_autoriser_syndication_integrale' => 'Diffondere la versione integrale degli articoli nei file di syndication', |
|
| 477 | - 'item_choix_administrateurs' => 'le amministratrici', |
|
| 478 | - 'item_choix_generation_miniature' => 'Genera automaticamente le thumbnail delle immagini.', |
|
| 479 | - 'item_choix_non_generation_miniature' => 'Non creare le thumbnail delle immagini.', |
|
| 480 | - 'item_choix_redacteurs' => 'le redattrici', |
|
| 481 | - 'item_choix_visiteurs' => 'i visitatori del sito pubblico', |
|
| 482 | - 'item_creer_fichiers_authent' => 'Crea i file .htpasswd', |
|
| 483 | - 'item_login' => 'Login', |
|
| 484 | - 'item_messagerie_agenda' => 'Attiva la messaggistica e l’agenda', |
|
| 485 | - 'item_mots_cles_association_articles' => 'agli articoli', |
|
| 486 | - 'item_mots_cles_association_rubriques' => 'alle rubriche', |
|
| 487 | - 'item_mots_cles_association_sites' => 'ai siti repertoriati o in syndication.', |
|
| 488 | - 'item_non' => 'No', |
|
| 489 | - 'item_non_accepter_inscriptions' => 'Non accettare le iscrizioni', |
|
| 490 | - 'item_non_activer_messages_avertissement' => 'Nessun messaggio d’avvertimento', |
|
| 491 | - 'item_non_afficher_calendrier' => 'Non pubblicare nel calendario', |
|
| 492 | - 'item_non_autoriser_syndication_integrale' => 'Diffondere solo un riassunto', |
|
| 493 | - 'item_non_creer_fichiers_authent' => 'Non creare questi file', |
|
| 494 | - 'item_non_messagerie_agenda' => 'Disattiva la messaggistica e l’agenda', |
|
| 495 | - 'item_non_publier_articles' => 'Non pubblicare gli articoli prima della data impostata.', |
|
| 496 | - 'item_nouvel_auteur' => 'Nuova autrice', |
|
| 497 | - 'item_nouvelle_rubrique' => 'Nuova rubrica', |
|
| 498 | - 'item_oui' => 'Sì', |
|
| 499 | - 'item_publier_articles' => 'Pubblica gli articoli indipendentemente dalla data impostata.', |
|
| 500 | - 'item_reponse_article' => 'Risposta all’articolo ', |
|
| 501 | - 'item_visiteur' => 'visitatore', |
|
| 438 | + 'info_travail_colaboratif' => 'Lavoro di collaborazione sugli articoli', |
|
| 439 | + 'info_un_article' => 'un articolo, ', |
|
| 440 | + 'info_un_site' => 'un sito, ', |
|
| 441 | + 'info_une_rubrique' => 'una rubrica, ', |
|
| 442 | + 'info_une_rubrique_02' => '1 rubrica', |
|
| 443 | + 'info_url' => 'URL:', |
|
| 444 | + 'info_urlref' => 'Link ipertestuale:', |
|
| 445 | + 'info_utilisation_spip' => 'Puoi ora cominciare ad utilizzare il sistema di pubblicazione assistita...', |
|
| 446 | + 'info_visites_par_mois' => 'Visualizzazione per mese:', |
|
| 447 | + 'info_visiteur_1' => 'Visitatori', |
|
| 448 | + 'info_visiteur_2' => 'del sito pubblico', |
|
| 449 | + 'info_visiteurs' => 'Visitatori', |
|
| 450 | + 'info_visiteurs_02' => 'Visitatori del sito pubblico', |
|
| 451 | + 'install_adresse_base_hebergeur' => 'Indirizzo del database attribuito dal provider', |
|
| 452 | + 'install_echec_annonce' => 'L’installazione potrebbe fallire oppure causare problemi di funzionalità al sito...', |
|
| 453 | + 'install_extension_mbstring' => 'SPIP non funziona con:', |
|
| 454 | + 'install_extension_php_obligatoire' => 'SPIP esige l’estensione php:', |
|
| 455 | + 'install_login_base_hebergeur' => 'Login di connessione attribuito dal provider', |
|
| 456 | + 'install_nom_base_hebergeur' => 'Nome del database attribuito dal provider:', |
|
| 457 | + 'install_pas_table' => 'Database attualmente senza tabelle', |
|
| 458 | + 'install_pass_base_hebergeur' => 'Password di connessione attribuito dal provider', |
|
| 459 | + 'install_php_version' => 'PHP versione @version@ insufficiente (minimo = @minimum@)', |
|
| 460 | + 'install_select_langue' => 'Seleziona una lingua e poi clicca sul bottone « Avanti » per lanciare la procedura di installazione.', |
|
| 461 | + 'install_select_type_db' => 'Indicare il tipo di database:', |
|
| 462 | + 'install_select_type_mysql' => 'MySQL', |
|
| 463 | + 'install_select_type_sqlite2' => 'SQLite 2', |
|
| 464 | + 'install_select_type_sqlite3' => 'SQLite 3', |
|
| 465 | + 'install_serveur_hebergeur' => 'Server del database attribuito dall’hoster', |
|
| 466 | + 'install_table_prefix_hebergeur' => 'Prefisso della tabella attribuito dal provider:', |
|
| 467 | + 'install_tables_base' => 'Tabelle del database', |
|
| 468 | + 'install_types_db_connus' => 'SPIP può utilizzare <b>MySQL</b> (il più diffuso) e <b>SQLite</b>.', |
|
| 469 | + 'install_types_db_connus_avertissement' => 'Il supporto <b>PostgreSQL</b> viene proposto a titolo sperimentale', # RELIRE |
|
| 470 | + 'intem_redacteur' => 'redattrice', |
|
| 471 | + 'intitule_licence' => 'Licenza', |
|
| 472 | + 'item_accepter_inscriptions' => 'Accetta le iscrizioni', |
|
| 473 | + 'item_activer_messages_avertissement' => 'Attiva i messaggi d’avvertimento', |
|
| 474 | + 'item_administrateur_2' => 'amministratrice', |
|
| 475 | + 'item_afficher_calendrier' => 'Pubblica nel calendario', |
|
| 476 | + 'item_autoriser_syndication_integrale' => 'Diffondere la versione integrale degli articoli nei file di syndication', |
|
| 477 | + 'item_choix_administrateurs' => 'le amministratrici', |
|
| 478 | + 'item_choix_generation_miniature' => 'Genera automaticamente le thumbnail delle immagini.', |
|
| 479 | + 'item_choix_non_generation_miniature' => 'Non creare le thumbnail delle immagini.', |
|
| 480 | + 'item_choix_redacteurs' => 'le redattrici', |
|
| 481 | + 'item_choix_visiteurs' => 'i visitatori del sito pubblico', |
|
| 482 | + 'item_creer_fichiers_authent' => 'Crea i file .htpasswd', |
|
| 483 | + 'item_login' => 'Login', |
|
| 484 | + 'item_messagerie_agenda' => 'Attiva la messaggistica e l’agenda', |
|
| 485 | + 'item_mots_cles_association_articles' => 'agli articoli', |
|
| 486 | + 'item_mots_cles_association_rubriques' => 'alle rubriche', |
|
| 487 | + 'item_mots_cles_association_sites' => 'ai siti repertoriati o in syndication.', |
|
| 488 | + 'item_non' => 'No', |
|
| 489 | + 'item_non_accepter_inscriptions' => 'Non accettare le iscrizioni', |
|
| 490 | + 'item_non_activer_messages_avertissement' => 'Nessun messaggio d’avvertimento', |
|
| 491 | + 'item_non_afficher_calendrier' => 'Non pubblicare nel calendario', |
|
| 492 | + 'item_non_autoriser_syndication_integrale' => 'Diffondere solo un riassunto', |
|
| 493 | + 'item_non_creer_fichiers_authent' => 'Non creare questi file', |
|
| 494 | + 'item_non_messagerie_agenda' => 'Disattiva la messaggistica e l’agenda', |
|
| 495 | + 'item_non_publier_articles' => 'Non pubblicare gli articoli prima della data impostata.', |
|
| 496 | + 'item_nouvel_auteur' => 'Nuova autrice', |
|
| 497 | + 'item_nouvelle_rubrique' => 'Nuova rubrica', |
|
| 498 | + 'item_oui' => 'Sì', |
|
| 499 | + 'item_publier_articles' => 'Pubblica gli articoli indipendentemente dalla data impostata.', |
|
| 500 | + 'item_reponse_article' => 'Risposta all’articolo ', |
|
| 501 | + 'item_visiteur' => 'visitatore', |
|
| 502 | 502 | |
| 503 | - // J |
|
| 504 | - 'jour_non_connu_nc' => 'n.c.', |
|
| 503 | + // J |
|
| 504 | + 'jour_non_connu_nc' => 'n.c.', |
|
| 505 | 505 | |
| 506 | - // L |
|
| 507 | - 'lien_ajouter_auteur' => 'Aggiungi questa autrice', |
|
| 508 | - 'lien_email' => 'email', |
|
| 509 | - 'lien_nom_site' => 'NOME DEL SITO:', |
|
| 510 | - 'lien_retirer_auteur' => 'Rimuovere l’autrice', |
|
| 511 | - 'lien_site' => 'sito', |
|
| 512 | - 'lien_tout_deplier' => 'Espandi', |
|
| 513 | - 'lien_tout_replier' => 'Richiudi', |
|
| 514 | - 'lien_tout_supprimer' => 'Eliminare tutto', |
|
| 515 | - 'lien_trier_nom' => 'Ordina per nome', |
|
| 516 | - 'lien_trier_nombre_articles' => 'Ordina per numero di articoli', |
|
| 517 | - 'lien_trier_statut' => 'Ordina per status', |
|
| 518 | - 'lien_voir_en_ligne' => 'VEDI ON LINE:', |
|
| 519 | - 'logo_article' => 'Logo dell’articolo', |
|
| 520 | - 'logo_auteur' => 'Logo dell’autrice', |
|
| 521 | - 'logo_rubrique' => 'Logo della rubrica', |
|
| 522 | - 'logo_site' => 'Logo di questo sito', |
|
| 523 | - 'logo_standard_rubrique' => 'Logo standard delle rubriche', |
|
| 524 | - 'logo_survol' => 'Logo rollover', # RELIRE |
|
| 506 | + // L |
|
| 507 | + 'lien_ajouter_auteur' => 'Aggiungi questa autrice', |
|
| 508 | + 'lien_email' => 'email', |
|
| 509 | + 'lien_nom_site' => 'NOME DEL SITO:', |
|
| 510 | + 'lien_retirer_auteur' => 'Rimuovere l’autrice', |
|
| 511 | + 'lien_site' => 'sito', |
|
| 512 | + 'lien_tout_deplier' => 'Espandi', |
|
| 513 | + 'lien_tout_replier' => 'Richiudi', |
|
| 514 | + 'lien_tout_supprimer' => 'Eliminare tutto', |
|
| 515 | + 'lien_trier_nom' => 'Ordina per nome', |
|
| 516 | + 'lien_trier_nombre_articles' => 'Ordina per numero di articoli', |
|
| 517 | + 'lien_trier_statut' => 'Ordina per status', |
|
| 518 | + 'lien_voir_en_ligne' => 'VEDI ON LINE:', |
|
| 519 | + 'logo_article' => 'Logo dell’articolo', |
|
| 520 | + 'logo_auteur' => 'Logo dell’autrice', |
|
| 521 | + 'logo_rubrique' => 'Logo della rubrica', |
|
| 522 | + 'logo_site' => 'Logo di questo sito', |
|
| 523 | + 'logo_standard_rubrique' => 'Logo standard delle rubriche', |
|
| 524 | + 'logo_survol' => 'Logo rollover', # RELIRE |
|
| 525 | 525 | |
| 526 | - // M |
|
| 527 | - 'menu_aide_installation_choix_base' => 'Scegliere il database', |
|
| 528 | - 'module_fichier_langue' => 'File lingua', |
|
| 529 | - 'module_raccourci' => 'Scorciatoia', |
|
| 530 | - 'module_texte_affiche' => 'Testo visualizzato', |
|
| 531 | - 'module_texte_explicatif' => 'È possibile inserire le scorciatoie nel modello di layout del proprio sito pubblico. Queste verranno tradotte automaticamente nelle diverse lingue (se esiste già un file lingua).', |
|
| 532 | - 'module_texte_traduction' => 'Il file lingua «@module@» è disponibile in:', |
|
| 533 | - 'mois_non_connu' => 'sconosciuto', |
|
| 526 | + // M |
|
| 527 | + 'menu_aide_installation_choix_base' => 'Scegliere il database', |
|
| 528 | + 'module_fichier_langue' => 'File lingua', |
|
| 529 | + 'module_raccourci' => 'Scorciatoia', |
|
| 530 | + 'module_texte_affiche' => 'Testo visualizzato', |
|
| 531 | + 'module_texte_explicatif' => 'È possibile inserire le scorciatoie nel modello di layout del proprio sito pubblico. Queste verranno tradotte automaticamente nelle diverse lingue (se esiste già un file lingua).', |
|
| 532 | + 'module_texte_traduction' => 'Il file lingua «@module@» è disponibile in:', |
|
| 533 | + 'mois_non_connu' => 'sconosciuto', |
|
| 534 | 534 | |
| 535 | - // O |
|
| 536 | - 'onglet_contenu' => 'Contenuto', |
|
| 537 | - 'onglet_declarer_une_autre_base' => 'Dichiarare un altro database', |
|
| 538 | - 'onglet_discuter' => 'Discuti', |
|
| 539 | - 'onglet_interactivite' => 'Interattività', |
|
| 540 | - 'onglet_proprietes' => 'Proprietà', |
|
| 541 | - 'onglet_repartition_actuelle' => 'attualmente', |
|
| 542 | - 'onglet_sous_rubriques' => 'Sotto-rubriche', |
|
| 535 | + // O |
|
| 536 | + 'onglet_contenu' => 'Contenuto', |
|
| 537 | + 'onglet_declarer_une_autre_base' => 'Dichiarare un altro database', |
|
| 538 | + 'onglet_discuter' => 'Discuti', |
|
| 539 | + 'onglet_interactivite' => 'Interattività', |
|
| 540 | + 'onglet_proprietes' => 'Proprietà', |
|
| 541 | + 'onglet_repartition_actuelle' => 'attualmente', |
|
| 542 | + 'onglet_sous_rubriques' => 'Sotto-rubriche', |
|
| 543 | 543 | |
| 544 | - // P |
|
| 545 | - 'page_pas_proxy' => 'Questa pagina non deve passare attraverso il proxy', |
|
| 546 | - 'pas_de_proxy_pour' => 'Se necessario, indicare i server o i domini per i quali non si deve applicare questo proxy (per esempio: @exemple@)', |
|
| 547 | - 'plugin_charge_paquet' => 'Caricamento del pacchetto @name@', |
|
| 548 | - 'plugin_erreur_charger' => 'errore: impossibile caricare @zip@', |
|
| 549 | - 'plugin_erreur_droit1' => 'La cartella <code>@dest@</code> non ha i permessi di scrittura.', |
|
| 550 | - 'plugin_erreur_droit2' => 'Verificare i diritti su questa cartella (e, se necessario, crearla), o installare i file tramite FTP.', |
|
| 551 | - 'plugin_erreur_zip' => 'fallimento pclzip: errore @status@', |
|
| 552 | - 'plugin_etat_developpement' => 'in corso di sviluppo', |
|
| 553 | - 'plugin_etat_experimental' => 'sperimentale', |
|
| 554 | - 'plugin_etat_stable' => 'stabile', |
|
| 555 | - 'plugin_etat_test' => 'in prova', |
|
| 556 | - 'plugin_impossible_activer' => 'Impossibile attivare il plug-in @plugin@', |
|
| 557 | - 'plugin_info_automatique1' => 'Se si desidera autorizzare l’installazione automatica dei plug-in è necessario: ', |
|
| 558 | - 'plugin_info_automatique2' => 'creare una cartella <code>@rep@</code>;', |
|
| 559 | - 'plugin_info_automatique3' => 'verificare che il server sia autorizzato a scrivere in questa cartella.', |
|
| 560 | - 'plugin_info_automatique_creer' => 'da creare alla radice del sito.', |
|
| 561 | - 'plugin_info_automatique_exemples' => 'esempi:', |
|
| 562 | - 'plugin_info_automatique_ftp' => 'È possibile installare plug-in tramite FTP, nella cartella <tt>@rep@</tt>', |
|
| 563 | - 'plugin_info_automatique_lib' => 'Alcuni plug-in richiedono anche di poter trasferire dei file nella cartella <code>lib/</code>, da creare (se necessario) alla radice del sito.', |
|
| 564 | - 'plugin_info_automatique_liste' => 'Gli elenchi dei plug-in:', |
|
| 565 | - 'plugin_info_automatique_liste_officielle' => 'i plug-in ufficiali', |
|
| 566 | - 'plugin_info_automatique_liste_update' => 'Aggiornare gli elenchi', |
|
| 567 | - 'plugin_info_automatique_ou' => 'oppure...', |
|
| 568 | - 'plugin_info_automatique_select' => 'Selezionata un plug-in qui sotto: SPIP lo scaricherà e lo installerà nella cartella <code>@rep@</code>; se questo plug-in è già presente verrà aggiornato.', |
|
| 569 | - 'plugin_info_telecharger' => 'da scaricare da @url@ e da installare in @rep@', |
|
| 570 | - 'plugin_librairies_installees' => 'Librerie installate', |
|
| 571 | - 'plugin_necessite_lib' => 'Questo plug-in richiede la libreria @lib@', |
|
| 572 | - 'plugin_necessite_plugin' => 'Necessita il plug-in @plugin@ con almeno la versione @version@.', # MODIF |
|
| 573 | - 'plugin_necessite_spip' => 'Necessita SPIP con almeno la versione @version@.', |
|
| 574 | - 'plugin_source' => 'origine: ', |
|
| 575 | - 'plugin_titre_automatique' => 'Installazione automatica', |
|
| 576 | - 'plugin_titre_automatique_ajouter' => 'Aggiungere dei plug-in', |
|
| 577 | - 'plugin_zip_active' => 'Continuare per attivarlo', |
|
| 578 | - 'plugin_zip_adresse' => 'indicate qui sotto l’indirizzo di un file zip del plug-in da scaricare, oppure l’indirizzo di un elenco di plug-in.', |
|
| 579 | - 'plugin_zip_adresse_champ' => 'Indirizzo del plug-in o dell’elenco ', |
|
| 580 | - 'plugin_zip_content' => 'Esso contiene i file seguenti (@taille@),<br />pronti per essere installati nella cartella <code>@rep@</code>', |
|
| 581 | - 'plugin_zip_installe_finie' => 'Il file @zip@ è stato decompresso e installato.', |
|
| 582 | - 'plugin_zip_installe_rep_finie' => 'Il file @zip@ è stato decompresso e installato nella cartella @rep@', |
|
| 583 | - 'plugin_zip_installer' => 'Ora è possibile installarlo.', |
|
| 584 | - 'plugin_zip_telecharge' => 'Il file @zip@ è stato scaricato', |
|
| 585 | - 'plugins_actifs' => '@count@ plug-in attivati.', |
|
| 586 | - 'plugins_compte' => '@count@ plug-in', |
|
| 587 | - 'plugins_disponibles' => '@count@ plug-in disponibili.', |
|
| 588 | - 'plugins_erreur' => 'Errore nei plug-in: @plugins@', |
|
| 589 | - 'plugins_liste' => 'Elenco dei plugin', |
|
| 590 | - 'plugins_vue_hierarchie' => 'Struttura gerarchica', |
|
| 591 | - 'plugins_vue_liste' => 'Elenco', |
|
| 592 | - 'protocole_ldap' => 'Versione del protocollo:', |
|
| 544 | + // P |
|
| 545 | + 'page_pas_proxy' => 'Questa pagina non deve passare attraverso il proxy', |
|
| 546 | + 'pas_de_proxy_pour' => 'Se necessario, indicare i server o i domini per i quali non si deve applicare questo proxy (per esempio: @exemple@)', |
|
| 547 | + 'plugin_charge_paquet' => 'Caricamento del pacchetto @name@', |
|
| 548 | + 'plugin_erreur_charger' => 'errore: impossibile caricare @zip@', |
|
| 549 | + 'plugin_erreur_droit1' => 'La cartella <code>@dest@</code> non ha i permessi di scrittura.', |
|
| 550 | + 'plugin_erreur_droit2' => 'Verificare i diritti su questa cartella (e, se necessario, crearla), o installare i file tramite FTP.', |
|
| 551 | + 'plugin_erreur_zip' => 'fallimento pclzip: errore @status@', |
|
| 552 | + 'plugin_etat_developpement' => 'in corso di sviluppo', |
|
| 553 | + 'plugin_etat_experimental' => 'sperimentale', |
|
| 554 | + 'plugin_etat_stable' => 'stabile', |
|
| 555 | + 'plugin_etat_test' => 'in prova', |
|
| 556 | + 'plugin_impossible_activer' => 'Impossibile attivare il plug-in @plugin@', |
|
| 557 | + 'plugin_info_automatique1' => 'Se si desidera autorizzare l’installazione automatica dei plug-in è necessario: ', |
|
| 558 | + 'plugin_info_automatique2' => 'creare una cartella <code>@rep@</code>;', |
|
| 559 | + 'plugin_info_automatique3' => 'verificare che il server sia autorizzato a scrivere in questa cartella.', |
|
| 560 | + 'plugin_info_automatique_creer' => 'da creare alla radice del sito.', |
|
| 561 | + 'plugin_info_automatique_exemples' => 'esempi:', |
|
| 562 | + 'plugin_info_automatique_ftp' => 'È possibile installare plug-in tramite FTP, nella cartella <tt>@rep@</tt>', |
|
| 563 | + 'plugin_info_automatique_lib' => 'Alcuni plug-in richiedono anche di poter trasferire dei file nella cartella <code>lib/</code>, da creare (se necessario) alla radice del sito.', |
|
| 564 | + 'plugin_info_automatique_liste' => 'Gli elenchi dei plug-in:', |
|
| 565 | + 'plugin_info_automatique_liste_officielle' => 'i plug-in ufficiali', |
|
| 566 | + 'plugin_info_automatique_liste_update' => 'Aggiornare gli elenchi', |
|
| 567 | + 'plugin_info_automatique_ou' => 'oppure...', |
|
| 568 | + 'plugin_info_automatique_select' => 'Selezionata un plug-in qui sotto: SPIP lo scaricherà e lo installerà nella cartella <code>@rep@</code>; se questo plug-in è già presente verrà aggiornato.', |
|
| 569 | + 'plugin_info_telecharger' => 'da scaricare da @url@ e da installare in @rep@', |
|
| 570 | + 'plugin_librairies_installees' => 'Librerie installate', |
|
| 571 | + 'plugin_necessite_lib' => 'Questo plug-in richiede la libreria @lib@', |
|
| 572 | + 'plugin_necessite_plugin' => 'Necessita il plug-in @plugin@ con almeno la versione @version@.', # MODIF |
|
| 573 | + 'plugin_necessite_spip' => 'Necessita SPIP con almeno la versione @version@.', |
|
| 574 | + 'plugin_source' => 'origine: ', |
|
| 575 | + 'plugin_titre_automatique' => 'Installazione automatica', |
|
| 576 | + 'plugin_titre_automatique_ajouter' => 'Aggiungere dei plug-in', |
|
| 577 | + 'plugin_zip_active' => 'Continuare per attivarlo', |
|
| 578 | + 'plugin_zip_adresse' => 'indicate qui sotto l’indirizzo di un file zip del plug-in da scaricare, oppure l’indirizzo di un elenco di plug-in.', |
|
| 579 | + 'plugin_zip_adresse_champ' => 'Indirizzo del plug-in o dell’elenco ', |
|
| 580 | + 'plugin_zip_content' => 'Esso contiene i file seguenti (@taille@),<br />pronti per essere installati nella cartella <code>@rep@</code>', |
|
| 581 | + 'plugin_zip_installe_finie' => 'Il file @zip@ è stato decompresso e installato.', |
|
| 582 | + 'plugin_zip_installe_rep_finie' => 'Il file @zip@ è stato decompresso e installato nella cartella @rep@', |
|
| 583 | + 'plugin_zip_installer' => 'Ora è possibile installarlo.', |
|
| 584 | + 'plugin_zip_telecharge' => 'Il file @zip@ è stato scaricato', |
|
| 585 | + 'plugins_actifs' => '@count@ plug-in attivati.', |
|
| 586 | + 'plugins_compte' => '@count@ plug-in', |
|
| 587 | + 'plugins_disponibles' => '@count@ plug-in disponibili.', |
|
| 588 | + 'plugins_erreur' => 'Errore nei plug-in: @plugins@', |
|
| 589 | + 'plugins_liste' => 'Elenco dei plugin', |
|
| 590 | + 'plugins_vue_hierarchie' => 'Struttura gerarchica', |
|
| 591 | + 'plugins_vue_liste' => 'Elenco', |
|
| 592 | + 'protocole_ldap' => 'Versione del protocollo:', |
|
| 593 | 593 | |
| 594 | - // R |
|
| 595 | - 'repertoire_plugins' => 'Cartella:', |
|
| 596 | - 'required' => '(obbligatorio)', # MODIF |
|
| 594 | + // R |
|
| 595 | + 'repertoire_plugins' => 'Cartella:', |
|
| 596 | + 'required' => '(obbligatorio)', # MODIF |
|
| 597 | 597 | |
| 598 | - // S |
|
| 599 | - 'sans_heure' => 'ora mancante', |
|
| 600 | - 'statut_admin_restreint' => 'admin limitato', # RELIRE |
|
| 598 | + // S |
|
| 599 | + 'sans_heure' => 'ora mancante', |
|
| 600 | + 'statut_admin_restreint' => 'admin limitato', # RELIRE |
|
| 601 | 601 | |
| 602 | - // T |
|
| 603 | - 'taille_cache_image' => 'Le immagini elaborate automaticamente da SPIP (icone dei documenti, titoli in formato grafico, funzioni matematiche in formato TeX...) occupano nella cartella @dir@ in tutto @taille@.', |
|
| 604 | - 'taille_cache_infinie' => 'Questo sito non prevede limiti alle dimensioni della cartella della cache.', |
|
| 605 | - 'taille_cache_maxi' => 'SPIP tenta di limitare le dimensioni della cartella della cache di questo sito a circa <b>@octets@</b> di dati.', |
|
| 606 | - 'taille_cache_octets' => 'Attualmente la cache è di circa @octets@.', # RELIRE |
|
| 607 | - 'taille_cache_vide' => 'La cache è vuota.', |
|
| 608 | - 'taille_repertoire_cache' => 'Dimensioni della cartella di cache', |
|
| 609 | - 'text_article_propose_publication' => 'Articolo proposto per la pubblicazione. ', |
|
| 610 | - 'texte_acces_ldap_anonyme_1' => 'Alcuni server LDAP non consentono accessi anonimi. In questo caso si deve specificare un identificatore d’accesso iniziale al fine di poter poi ricercare delle informazioni nell’elenco. Nella maggior parte dei casi tuttavia, i campi seguenti potranno essere lasciati vuoti.', |
|
| 611 | - 'texte_admin_effacer_01' => 'Questo commando cancella <i>tutto</i> il contenuto del database, |
|
| 602 | + // T |
|
| 603 | + 'taille_cache_image' => 'Le immagini elaborate automaticamente da SPIP (icone dei documenti, titoli in formato grafico, funzioni matematiche in formato TeX...) occupano nella cartella @dir@ in tutto @taille@.', |
|
| 604 | + 'taille_cache_infinie' => 'Questo sito non prevede limiti alle dimensioni della cartella della cache.', |
|
| 605 | + 'taille_cache_maxi' => 'SPIP tenta di limitare le dimensioni della cartella della cache di questo sito a circa <b>@octets@</b> di dati.', |
|
| 606 | + 'taille_cache_octets' => 'Attualmente la cache è di circa @octets@.', # RELIRE |
|
| 607 | + 'taille_cache_vide' => 'La cache è vuota.', |
|
| 608 | + 'taille_repertoire_cache' => 'Dimensioni della cartella di cache', |
|
| 609 | + 'text_article_propose_publication' => 'Articolo proposto per la pubblicazione. ', |
|
| 610 | + 'texte_acces_ldap_anonyme_1' => 'Alcuni server LDAP non consentono accessi anonimi. In questo caso si deve specificare un identificatore d’accesso iniziale al fine di poter poi ricercare delle informazioni nell’elenco. Nella maggior parte dei casi tuttavia, i campi seguenti potranno essere lasciati vuoti.', |
|
| 611 | + 'texte_admin_effacer_01' => 'Questo commando cancella <i>tutto</i> il contenuto del database, |
|
| 612 | 612 | compresi <i>tutti</i> i login delle redattrici e delle amministratrici. Dopo averlo eseguito, dovrai riavviare la procedura di installazione per ricreare un nuovo database e un primo ID amministrativo.', |
| 613 | - 'texte_adresse_annuaire_1' => '(Se la rubrica è installata nella stessa macchina di questo sito, dovrai probabilmente inserire "localhost".)', |
|
| 614 | - 'texte_ajout_auteur' => 'La seguente autrice è stata aggiunta all’articolo:', |
|
| 615 | - 'texte_annuaire_ldap_1' => 'Se hai accesso ad una rubrica (LDAP), puoi utilizzarla per importare automaticamente delle utenti sotto SPIP.', |
|
| 616 | - 'texte_article_statut' => 'Questo articolo è:', |
|
| 617 | - 'texte_article_virtuel' => 'Articolo virtuale', |
|
| 618 | - 'texte_article_virtuel_reference' => '<b>Articolo virtuale:</b> articolo citato nel tuo sito SPIP, ma reindrizzato verso un’altro URL. Per eliminare il reindirizzamento, cancella l’URL qui sopra.', |
|
| 619 | - 'texte_aucun_resultat_auteur' => 'Nessun risultato per "@cherche_auteur@"', |
|
| 620 | - 'texte_auteur_messagerie' => 'Questo sito può costantemente visualizzare la lista delle redattrici collegate, permettendo lo scambio di messaggi in tempo reale. Si può però decidere di non comparire in questo elenco (rendendosi quindi «invisibili» alle altre utenti).', |
|
| 621 | - 'texte_auteurs' => 'LE AUTRICI', |
|
| 622 | - 'texte_choix_base_1' => 'Scegli il database:', |
|
| 623 | - 'texte_choix_base_2' => 'Il server SQL contiene diversi database.', |
|
| 624 | - 'texte_choix_base_3' => '<b>Seleziona</b> quello che è stato attribuito al tuo dominio:', |
|
| 625 | - 'texte_choix_table_prefix' => 'Prefisso delle tabelle:', |
|
| 626 | - 'texte_compte_element' => '@count@ elemento', |
|
| 627 | - 'texte_compte_elements' => '@count@ elementi', |
|
| 628 | - 'texte_conflit_edition_correction' => 'Controllare qui sotto le differenze tra le due versioni del testo; è possibile anche copiare le modifiche e poi ricominciare.', |
|
| 629 | - 'texte_connexion_mysql' => 'Consulta le informazioni fornite dal tuo hoster: devi poterci trovare, i codici di collegamento alla base di dati.', |
|
| 630 | - 'texte_contenu_article' => 'Contenuto dell’articolo in poche parole (<em>abstract</em>)', |
|
| 631 | - 'texte_contenu_articles' => 'A seconda del modello di presentazione adottato per il sito, puoi decidere |
|
| 613 | + 'texte_adresse_annuaire_1' => '(Se la rubrica è installata nella stessa macchina di questo sito, dovrai probabilmente inserire "localhost".)', |
|
| 614 | + 'texte_ajout_auteur' => 'La seguente autrice è stata aggiunta all’articolo:', |
|
| 615 | + 'texte_annuaire_ldap_1' => 'Se hai accesso ad una rubrica (LDAP), puoi utilizzarla per importare automaticamente delle utenti sotto SPIP.', |
|
| 616 | + 'texte_article_statut' => 'Questo articolo è:', |
|
| 617 | + 'texte_article_virtuel' => 'Articolo virtuale', |
|
| 618 | + 'texte_article_virtuel_reference' => '<b>Articolo virtuale:</b> articolo citato nel tuo sito SPIP, ma reindrizzato verso un’altro URL. Per eliminare il reindirizzamento, cancella l’URL qui sopra.', |
|
| 619 | + 'texte_aucun_resultat_auteur' => 'Nessun risultato per "@cherche_auteur@"', |
|
| 620 | + 'texte_auteur_messagerie' => 'Questo sito può costantemente visualizzare la lista delle redattrici collegate, permettendo lo scambio di messaggi in tempo reale. Si può però decidere di non comparire in questo elenco (rendendosi quindi «invisibili» alle altre utenti).', |
|
| 621 | + 'texte_auteurs' => 'LE AUTRICI', |
|
| 622 | + 'texte_choix_base_1' => 'Scegli il database:', |
|
| 623 | + 'texte_choix_base_2' => 'Il server SQL contiene diversi database.', |
|
| 624 | + 'texte_choix_base_3' => '<b>Seleziona</b> quello che è stato attribuito al tuo dominio:', |
|
| 625 | + 'texte_choix_table_prefix' => 'Prefisso delle tabelle:', |
|
| 626 | + 'texte_compte_element' => '@count@ elemento', |
|
| 627 | + 'texte_compte_elements' => '@count@ elementi', |
|
| 628 | + 'texte_conflit_edition_correction' => 'Controllare qui sotto le differenze tra le due versioni del testo; è possibile anche copiare le modifiche e poi ricominciare.', |
|
| 629 | + 'texte_connexion_mysql' => 'Consulta le informazioni fornite dal tuo hoster: devi poterci trovare, i codici di collegamento alla base di dati.', |
|
| 630 | + 'texte_contenu_article' => 'Contenuto dell’articolo in poche parole (<em>abstract</em>)', |
|
| 631 | + 'texte_contenu_articles' => 'A seconda del modello di presentazione adottato per il sito, puoi decidere |
|
| 632 | 632 | che alcuni elementi degli articoli siano utilizzati oppure no. |
| 633 | 633 | Serviti dell’elenco qui sotto per indicare quali elementi rendere disponibili.', |
| 634 | - 'texte_crash_base' => 'Se il database è stato danneggiato, puoi tentare un ripristino automatico.', |
|
| 635 | - 'texte_creer_rubrique' => 'Prima di poter scrivere degli articoli,<br /> devi creare una rubrica.', |
|
| 636 | - 'texte_date_creation_article' => 'DATA DI CREAZIONE DELL’ARTICOLO:', |
|
| 637 | - 'texte_date_publication_anterieure' => 'DATA DI REDAZIONE ANTERIORE', |
|
| 638 | - 'texte_date_publication_anterieure_nonaffichee' => 'Non visualizzare la data di redazione anteriore.', |
|
| 639 | - 'texte_date_publication_article' => 'DATA DI PUBBLICAZIONE:', |
|
| 640 | - 'texte_descriptif_rapide' => 'Descrizione rapida', |
|
| 641 | - 'texte_effacer_base' => 'Cancella il database SPIP', |
|
| 642 | - 'texte_effacer_statistiques' => 'Cancellare le statistiche', |
|
| 643 | - 'texte_en_cours_validation' => 'I contenuti qui di seguito sono in attesa di validazione. ', # RELIRE |
|
| 644 | - 'texte_enrichir_mise_a_jour' => 'Puoi arricchire la formattazione del testo utilizzando le «scorciatoie tipografiche»', |
|
| 645 | - 'texte_fichier_authent' => '<b>SPIP deve creare i file speciali |
|
| 634 | + 'texte_crash_base' => 'Se il database è stato danneggiato, puoi tentare un ripristino automatico.', |
|
| 635 | + 'texte_creer_rubrique' => 'Prima di poter scrivere degli articoli,<br /> devi creare una rubrica.', |
|
| 636 | + 'texte_date_creation_article' => 'DATA DI CREAZIONE DELL’ARTICOLO:', |
|
| 637 | + 'texte_date_publication_anterieure' => 'DATA DI REDAZIONE ANTERIORE', |
|
| 638 | + 'texte_date_publication_anterieure_nonaffichee' => 'Non visualizzare la data di redazione anteriore.', |
|
| 639 | + 'texte_date_publication_article' => 'DATA DI PUBBLICAZIONE:', |
|
| 640 | + 'texte_descriptif_rapide' => 'Descrizione rapida', |
|
| 641 | + 'texte_effacer_base' => 'Cancella il database SPIP', |
|
| 642 | + 'texte_effacer_statistiques' => 'Cancellare le statistiche', |
|
| 643 | + 'texte_en_cours_validation' => 'I contenuti qui di seguito sono in attesa di validazione. ', # RELIRE |
|
| 644 | + 'texte_enrichir_mise_a_jour' => 'Puoi arricchire la formattazione del testo utilizzando le «scorciatoie tipografiche»', |
|
| 645 | + 'texte_fichier_authent' => '<b>SPIP deve creare i file speciali |
|
| 646 | 646 | <tt>.htpasswd</tt> e <tt>.htpasswd-admin</tt> nella cartella @dossier@ ?</b> |
| 647 | 647 | <p>Questi file possono servire a limitare l’accesso alle autrici |
| 648 | 648 | e alle amministratrici in particolari aree del vostro sito (per esempio, per un programma esterno di statistiche).</p> |
| 649 | 649 | <p>Se ciò non è necessario, lasciare quest’opzione al suo valore predefinito (nessuna creazione |
| 650 | 650 | di file).</p>', # RELIRE |
| 651 | - 'texte_informations_personnelles_1' => 'Il sistema creerà un tuo accesso personalizzato al sito.', |
|
| 652 | - 'texte_informations_personnelles_2' => '(Nota : trattandosi di una reinstallazione, se il tuo accesso funziona ancora potete ', # RELIRE |
|
| 653 | - 'texte_introductif_article' => 'Testo introduttivo dell’articolo', |
|
| 654 | - 'texte_jeu_caractere' => 'Si consiglia di utilizzare sul proprio sito l’alfabeto universale (<tt>utf-8</tt>): esso permette di visualizzare i testi in tutte le lingue e non pone problemi di compatibilità con i browser moderni.', |
|
| 655 | - 'texte_jeu_caractere_3' => 'Il tuo sito usa attualmente il set di caratteri:', |
|
| 656 | - 'texte_jeu_caractere_4' => 'Se ciò non corrisponde alla realtà dei propri dati (a causa, per esempio, di un ripristino del database), o se <em>si avvia il sito</em> e si desidera partire con un altro set di caratteri è necessario indicare quest’ultimo qui:', |
|
| 657 | - 'texte_login_ldap_1' => '(Lascia vuoto per un accesso anonimo, o inserisci il percorso completo, per esempio «<tt>uid=rossi, ou=users, dc=mio-dominio, dc=com</tt> ».)', |
|
| 658 | - 'texte_login_precaution' => 'Attenzione! Questo è l’ID con il quale sei attualmente collegato. |
|
| 651 | + 'texte_informations_personnelles_1' => 'Il sistema creerà un tuo accesso personalizzato al sito.', |
|
| 652 | + 'texte_informations_personnelles_2' => '(Nota : trattandosi di una reinstallazione, se il tuo accesso funziona ancora potete ', # RELIRE |
|
| 653 | + 'texte_introductif_article' => 'Testo introduttivo dell’articolo', |
|
| 654 | + 'texte_jeu_caractere' => 'Si consiglia di utilizzare sul proprio sito l’alfabeto universale (<tt>utf-8</tt>): esso permette di visualizzare i testi in tutte le lingue e non pone problemi di compatibilità con i browser moderni.', |
|
| 655 | + 'texte_jeu_caractere_3' => 'Il tuo sito usa attualmente il set di caratteri:', |
|
| 656 | + 'texte_jeu_caractere_4' => 'Se ciò non corrisponde alla realtà dei propri dati (a causa, per esempio, di un ripristino del database), o se <em>si avvia il sito</em> e si desidera partire con un altro set di caratteri è necessario indicare quest’ultimo qui:', |
|
| 657 | + 'texte_login_ldap_1' => '(Lascia vuoto per un accesso anonimo, o inserisci il percorso completo, per esempio «<tt>uid=rossi, ou=users, dc=mio-dominio, dc=com</tt> ».)', |
|
| 658 | + 'texte_login_precaution' => 'Attenzione! Questo è l’ID con il quale sei attualmente collegato. |
|
| 659 | 659 | Utilizza questo modulo con cognizione di causa...', |
| 660 | - 'texte_messagerie_agenda' => 'La messageria permette alle redattrici del sito di comunicare tra loro in maniera diretta nell’area riservata. Essa è associata a una agenda.', |
|
| 661 | - 'texte_mise_a_niveau_base_1' => 'Hai aggiornato i file SPIP. |
|
| 660 | + 'texte_messagerie_agenda' => 'La messageria permette alle redattrici del sito di comunicare tra loro in maniera diretta nell’area riservata. Essa è associata a una agenda.', |
|
| 661 | + 'texte_mise_a_niveau_base_1' => 'Hai aggiornato i file SPIP. |
|
| 662 | 662 | Adesso è necessario aggiornare il database.', |
| 663 | - 'texte_modifier_article' => 'Modifica l’articolo:', |
|
| 664 | - 'texte_multilinguisme' => 'Se desideri gestire gli articoli in diverse lingue, con un sistema di navigazione complesso, è possibile aggiungere un menu di selezione della lingua negli articoli e/o nelle rubriche, in funzione della struttura del sito.', # RELIRE |
|
| 665 | - 'texte_multilinguisme_trad' => 'È anche possibile attivare un sistema di gestione di link fra le diverse traduzioni relative ad alcuni elementi.', # RELIRE |
|
| 666 | - 'texte_non_compresse' => '<i>non compresso</i> (il tuo server non supporta questa funzionalità)', |
|
| 667 | - 'texte_nouvelle_version_spip_1' => 'Hai installato una nuova versione di SPIP.', |
|
| 668 | - 'texte_nouvelle_version_spip_2' => 'Questa nuova versione necessita un aggiornamento più radicale del solito. Se sei la webmistress del sito, cancella il file @connect@ e riprendi l’installazione al fine di aggiornare i parametri di connessione al database.<p> (NB: se hai dimenticato i parametri di connessione, rileggi il file @connect@ prima di cancellarlo...)</p>', # RELIRE |
|
| 669 | - 'texte_operation_echec' => 'Torna alla pagina precedente, seleziona un altro database o creane uno nuovo. Verifica le informazioni fornite dal tuo hoster.', |
|
| 670 | - 'texte_plus_trois_car' => 'più di tre caratteri', |
|
| 671 | - 'texte_plusieurs_articles' => 'Diversi autori trovati per "@cherche_auteur@":', |
|
| 672 | - 'texte_port_annuaire' => '(Il valore predefinito è in genere quello adatto.)', |
|
| 673 | - 'texte_presente_plugin' => 'Questa pagina elenca i plugin disponibili sul sito. È possibile attivare i plugin necessari selezionando la casella corrispondente.', |
|
| 674 | - 'texte_proposer_publication' => 'Quando l’articolo è completo,<br /> puoi proporne la pubblicazione.', |
|
| 675 | - 'texte_proxy' => 'In alcuni casi (intranet, reti protette...), i siti distanti (documetazione di SPIP, siti in syndication, ecc.) sono accessibili unicamente attraverso un <i>proxy HTTP</i>. In questo caso, va indicato l’indirizzo del server nella forma @proxy_en_cours@. In genere questa casella va lasciata vuota.', |
|
| 676 | - 'texte_publication_articles_post_dates' => 'Come si deve comportare SPIP quando gli articoli hanno |
|
| 663 | + 'texte_modifier_article' => 'Modifica l’articolo:', |
|
| 664 | + 'texte_multilinguisme' => 'Se desideri gestire gli articoli in diverse lingue, con un sistema di navigazione complesso, è possibile aggiungere un menu di selezione della lingua negli articoli e/o nelle rubriche, in funzione della struttura del sito.', # RELIRE |
|
| 665 | + 'texte_multilinguisme_trad' => 'È anche possibile attivare un sistema di gestione di link fra le diverse traduzioni relative ad alcuni elementi.', # RELIRE |
|
| 666 | + 'texte_non_compresse' => '<i>non compresso</i> (il tuo server non supporta questa funzionalità)', |
|
| 667 | + 'texte_nouvelle_version_spip_1' => 'Hai installato una nuova versione di SPIP.', |
|
| 668 | + 'texte_nouvelle_version_spip_2' => 'Questa nuova versione necessita un aggiornamento più radicale del solito. Se sei la webmistress del sito, cancella il file @connect@ e riprendi l’installazione al fine di aggiornare i parametri di connessione al database.<p> (NB: se hai dimenticato i parametri di connessione, rileggi il file @connect@ prima di cancellarlo...)</p>', # RELIRE |
|
| 669 | + 'texte_operation_echec' => 'Torna alla pagina precedente, seleziona un altro database o creane uno nuovo. Verifica le informazioni fornite dal tuo hoster.', |
|
| 670 | + 'texte_plus_trois_car' => 'più di tre caratteri', |
|
| 671 | + 'texte_plusieurs_articles' => 'Diversi autori trovati per "@cherche_auteur@":', |
|
| 672 | + 'texte_port_annuaire' => '(Il valore predefinito è in genere quello adatto.)', |
|
| 673 | + 'texte_presente_plugin' => 'Questa pagina elenca i plugin disponibili sul sito. È possibile attivare i plugin necessari selezionando la casella corrispondente.', |
|
| 674 | + 'texte_proposer_publication' => 'Quando l’articolo è completo,<br /> puoi proporne la pubblicazione.', |
|
| 675 | + 'texte_proxy' => 'In alcuni casi (intranet, reti protette...), i siti distanti (documetazione di SPIP, siti in syndication, ecc.) sono accessibili unicamente attraverso un <i>proxy HTTP</i>. In questo caso, va indicato l’indirizzo del server nella forma @proxy_en_cours@. In genere questa casella va lasciata vuota.', |
|
| 676 | + 'texte_publication_articles_post_dates' => 'Come si deve comportare SPIP quando gli articoli hanno |
|
| 677 | 677 | una data di pubblicazione impostata nel futuro?', |
| 678 | - 'texte_rappel_selection_champs' => '[Non dimenticare di impostare correttamente questo campo]', |
|
| 679 | - 'texte_recalcul_page' => 'Se vuoi rigenerare |
|
| 678 | + 'texte_rappel_selection_champs' => '[Non dimenticare di impostare correttamente questo campo]', |
|
| 679 | + 'texte_recalcul_page' => 'Se vuoi rigenerare |
|
| 680 | 680 | una sola pagina, utilizza piuttosto lo spazio pubblico e clicca sul pulsante «rigenera».', |
| 681 | - 'texte_recuperer_base' => 'Ripara il database', |
|
| 682 | - 'texte_reference_mais_redirige' => 'articolo catalogato nel tuo sito SPIP, ma con reindirizzamento verso un altro URL.', |
|
| 683 | - 'texte_requetes_echouent' => '<b>Quando alcune query SQL falliscono |
|
| 681 | + 'texte_recuperer_base' => 'Ripara il database', |
|
| 682 | + 'texte_reference_mais_redirige' => 'articolo catalogato nel tuo sito SPIP, ma con reindirizzamento verso un altro URL.', |
|
| 683 | + 'texte_requetes_echouent' => '<b>Quando alcune query SQL falliscono |
|
| 684 | 684 | ripetutamente e senza un chiaro motivo, è possibile |
| 685 | 685 | che sia per colpa del database |
| 686 | 686 | stesso.</b><p> |
@@ -691,79 +691,79 @@ discard block |
||
| 691 | 691 | forse, delle informazioni preziose...</p><p> |
| 692 | 692 | Se il problema persiste, contattate la vostra |
| 693 | 693 | webmistress.</p>', # RELIRE |
| 694 | - 'texte_selection_langue_principale' => 'Puoi selezionare qui sotto la «lingua predefinita» del sito. Questa scelta non obbliga - fortunatamente! - a scrivere gli articoli nella stessa lingua, ma permette di determinare: |
|
| 694 | + 'texte_selection_langue_principale' => 'Puoi selezionare qui sotto la «lingua predefinita» del sito. Questa scelta non obbliga - fortunatamente! - a scrivere gli articoli nella stessa lingua, ma permette di determinare: |
|
| 695 | 695 | <ul><li> il formato di default delle date sul sito pubblico;</li> |
| 696 | 696 | <li> la tipologia di motore tipografico che SPIP deve utilizzare per la resa del testo;</li> |
| 697 | 697 | <li> la lingua utilizzata nelle finestre di dialogo del sito pubblico;</li> |
| 698 | 698 | <li> la lingua di default nell’area riservata all’amministrazione.</li></ul>', |
| 699 | - 'texte_sous_titre' => 'Sottotitolo', |
|
| 700 | - 'texte_statistiques_visites' => '(barre scure: domenica / curve scure: evoluzione della media)', |
|
| 701 | - 'texte_statut_attente_validation' => 'in attesa di convalida', |
|
| 702 | - 'texte_statut_publies' => 'pubblicato on line', |
|
| 703 | - 'texte_statut_refuses' => 'rifiutati', |
|
| 704 | - 'texte_suppression_fichiers' => 'Utilizza questo commando per cancellare tutti i file presenti nella |
|
| 699 | + 'texte_sous_titre' => 'Sottotitolo', |
|
| 700 | + 'texte_statistiques_visites' => '(barre scure: domenica / curve scure: evoluzione della media)', |
|
| 701 | + 'texte_statut_attente_validation' => 'in attesa di convalida', |
|
| 702 | + 'texte_statut_publies' => 'pubblicato on line', |
|
| 703 | + 'texte_statut_refuses' => 'rifiutati', |
|
| 704 | + 'texte_suppression_fichiers' => 'Utilizza questo commando per cancellare tutti i file presenti nella |
|
| 705 | 705 | cache di SPIP. Ciò permette ad esempio di forzare la rigenerazione di tutte le pagine se hai fatto delle importanti modifiche di grafica o di struttura del sito.', |
| 706 | - 'texte_sur_titre' => 'Occhiello', |
|
| 707 | - 'texte_table_ok' => ': questa tabella è OK.', |
|
| 708 | - 'texte_tentative_recuperation' => 'Tentativo di ripristino', |
|
| 709 | - 'texte_tenter_reparation' => 'Tenta un ripristino del database', |
|
| 710 | - 'texte_test_proxy' => 'Per fare una prova di questo proxy, indicare qui l’indirizzo |
|
| 706 | + 'texte_sur_titre' => 'Occhiello', |
|
| 707 | + 'texte_table_ok' => ': questa tabella è OK.', |
|
| 708 | + 'texte_tentative_recuperation' => 'Tentativo di ripristino', |
|
| 709 | + 'texte_tenter_reparation' => 'Tenta un ripristino del database', |
|
| 710 | + 'texte_test_proxy' => 'Per fare una prova di questo proxy, indicare qui l’indirizzo |
|
| 711 | 711 | di un sito Web da testare.', |
| 712 | - 'texte_titre_02' => 'Titolo:', |
|
| 713 | - 'texte_titre_obligatoire' => '<b>Titolo</b> [Obbligatorio]', |
|
| 714 | - 'texte_travail_article' => '@nom_auteur_modif@ ha lavorato su questo articolo @date_diff@ minuti fa', |
|
| 715 | - 'texte_travail_collaboratif' => 'Se diverse autrici lavorano spesso sullo stesso articolo, |
|
| 712 | + 'texte_titre_02' => 'Titolo:', |
|
| 713 | + 'texte_titre_obligatoire' => '<b>Titolo</b> [Obbligatorio]', |
|
| 714 | + 'texte_travail_article' => '@nom_auteur_modif@ ha lavorato su questo articolo @date_diff@ minuti fa', |
|
| 715 | + 'texte_travail_collaboratif' => 'Se diverse autrici lavorano spesso sullo stesso articolo, |
|
| 716 | 716 | il sistema può segnalare gli articoli «aperti» |
| 717 | 717 | di recente al fine di evitare modifiche simultanee. |
| 718 | 718 | Questa opzione è disattivata di default |
| 719 | 719 | per evitare di generare messaggi d’avvertimento intempestivi.', |
| 720 | - 'texte_vide' => 'vuoto', |
|
| 721 | - 'texte_vider_cache' => 'Svuota la cache', |
|
| 722 | - 'titre_admin_tech' => 'Manutenzione tecnica', |
|
| 723 | - 'titre_admin_vider' => 'Manutenzione tecnica', |
|
| 724 | - 'titre_cadre_afficher_article' => 'Visualizza gli articoli', |
|
| 725 | - 'titre_cadre_afficher_traductions' => 'Visualizzare lo stato delle traduzioni per le seguenti lingue:', |
|
| 726 | - 'titre_cadre_ajouter_auteur' => 'AGGIUNGI UN’AUTRICE: ', |
|
| 727 | - 'titre_cadre_interieur_rubrique' => 'All’interno della rubrica', |
|
| 728 | - 'titre_cadre_numero_auteur' => 'AUTRICE NUMERO', |
|
| 729 | - 'titre_cadre_signature_obligatoire' => '<b>Firma</b> [Obbligatoria]<br />', |
|
| 730 | - 'titre_config_contenu_notifications' => 'Notifiche', |
|
| 731 | - 'titre_config_contenu_prive' => 'Nell’area riservata', |
|
| 732 | - 'titre_config_contenu_public' => 'Sul sito pubblico', |
|
| 733 | - 'titre_config_fonctions' => 'Configurazione del sito', |
|
| 734 | - 'titre_configuration' => 'Configurazione del sito', |
|
| 735 | - 'titre_conflit_edition' => 'Conflitto all’atto dell’edizione', |
|
| 736 | - 'titre_connexion_ldap' => 'Opzioni: <b>La connessione LDAP</b>', |
|
| 737 | - 'titre_groupe_mots' => 'GRUPPO DI PAROLE CHIAVE:', |
|
| 738 | - 'titre_langue_article' => 'Lingua dell’articolo', |
|
| 739 | - 'titre_langue_rubrique' => 'Lingua della rubrica', |
|
| 740 | - 'titre_langue_trad_article' => 'LINGUA E TRADUZIONI DELL’ARTICOLO', |
|
| 741 | - 'titre_les_articles' => 'GLI ARTICOLI', |
|
| 742 | - 'titre_messagerie_agenda' => 'Messagistica e agenda', |
|
| 743 | - 'titre_naviguer_dans_le_site' => 'Navigare nel sito...', |
|
| 744 | - 'titre_nouvelle_rubrique' => 'Nuova rubrica', |
|
| 745 | - 'titre_numero_rubrique' => 'RUBRICA NUMERO:', |
|
| 746 | - 'titre_page_articles_edit' => 'Modifica: @titre@', |
|
| 747 | - 'titre_page_articles_page' => 'Gli articoli', |
|
| 748 | - 'titre_page_articles_tous' => 'Tutto il sito', |
|
| 749 | - 'titre_page_calendrier' => 'Calendario @nom_mois@ @annee@', |
|
| 750 | - 'titre_page_config_contenu' => 'Configurazione del sito', |
|
| 751 | - 'titre_page_delete_all' => 'eliminazione totale e irreversible', |
|
| 752 | - 'titre_page_recherche' => 'Risultati della ricerca @recherche@', |
|
| 753 | - 'titre_page_statistiques_referers' => 'Statistiche (link al tuo sito)', |
|
| 754 | - 'titre_page_upgrade' => 'Aggiornamento di SPIP', |
|
| 755 | - 'titre_publication_articles_post_dates' => 'Pubblicazione di articoli postdatati', |
|
| 756 | - 'titre_reparation' => 'Riparazione', |
|
| 757 | - 'titre_suivi_petition' => 'Monitoraggio delle petizioni', |
|
| 758 | - 'tls_ldap' => 'Transport Layer Security:', |
|
| 759 | - 'trad_article_traduction' => 'Tutte le versioni di questo articolo:', |
|
| 760 | - 'trad_delier' => 'Non collegare più a queste traduzioni', # RELIRE |
|
| 761 | - 'trad_lier' => 'Questo articolo è una traduzione dell’articolo numero:', |
|
| 762 | - 'trad_new' => 'Scrivere una nuova traduzione', |
|
| 720 | + 'texte_vide' => 'vuoto', |
|
| 721 | + 'texte_vider_cache' => 'Svuota la cache', |
|
| 722 | + 'titre_admin_tech' => 'Manutenzione tecnica', |
|
| 723 | + 'titre_admin_vider' => 'Manutenzione tecnica', |
|
| 724 | + 'titre_cadre_afficher_article' => 'Visualizza gli articoli', |
|
| 725 | + 'titre_cadre_afficher_traductions' => 'Visualizzare lo stato delle traduzioni per le seguenti lingue:', |
|
| 726 | + 'titre_cadre_ajouter_auteur' => 'AGGIUNGI UN’AUTRICE: ', |
|
| 727 | + 'titre_cadre_interieur_rubrique' => 'All’interno della rubrica', |
|
| 728 | + 'titre_cadre_numero_auteur' => 'AUTRICE NUMERO', |
|
| 729 | + 'titre_cadre_signature_obligatoire' => '<b>Firma</b> [Obbligatoria]<br />', |
|
| 730 | + 'titre_config_contenu_notifications' => 'Notifiche', |
|
| 731 | + 'titre_config_contenu_prive' => 'Nell’area riservata', |
|
| 732 | + 'titre_config_contenu_public' => 'Sul sito pubblico', |
|
| 733 | + 'titre_config_fonctions' => 'Configurazione del sito', |
|
| 734 | + 'titre_configuration' => 'Configurazione del sito', |
|
| 735 | + 'titre_conflit_edition' => 'Conflitto all’atto dell’edizione', |
|
| 736 | + 'titre_connexion_ldap' => 'Opzioni: <b>La connessione LDAP</b>', |
|
| 737 | + 'titre_groupe_mots' => 'GRUPPO DI PAROLE CHIAVE:', |
|
| 738 | + 'titre_langue_article' => 'Lingua dell’articolo', |
|
| 739 | + 'titre_langue_rubrique' => 'Lingua della rubrica', |
|
| 740 | + 'titre_langue_trad_article' => 'LINGUA E TRADUZIONI DELL’ARTICOLO', |
|
| 741 | + 'titre_les_articles' => 'GLI ARTICOLI', |
|
| 742 | + 'titre_messagerie_agenda' => 'Messagistica e agenda', |
|
| 743 | + 'titre_naviguer_dans_le_site' => 'Navigare nel sito...', |
|
| 744 | + 'titre_nouvelle_rubrique' => 'Nuova rubrica', |
|
| 745 | + 'titre_numero_rubrique' => 'RUBRICA NUMERO:', |
|
| 746 | + 'titre_page_articles_edit' => 'Modifica: @titre@', |
|
| 747 | + 'titre_page_articles_page' => 'Gli articoli', |
|
| 748 | + 'titre_page_articles_tous' => 'Tutto il sito', |
|
| 749 | + 'titre_page_calendrier' => 'Calendario @nom_mois@ @annee@', |
|
| 750 | + 'titre_page_config_contenu' => 'Configurazione del sito', |
|
| 751 | + 'titre_page_delete_all' => 'eliminazione totale e irreversible', |
|
| 752 | + 'titre_page_recherche' => 'Risultati della ricerca @recherche@', |
|
| 753 | + 'titre_page_statistiques_referers' => 'Statistiche (link al tuo sito)', |
|
| 754 | + 'titre_page_upgrade' => 'Aggiornamento di SPIP', |
|
| 755 | + 'titre_publication_articles_post_dates' => 'Pubblicazione di articoli postdatati', |
|
| 756 | + 'titre_reparation' => 'Riparazione', |
|
| 757 | + 'titre_suivi_petition' => 'Monitoraggio delle petizioni', |
|
| 758 | + 'tls_ldap' => 'Transport Layer Security:', |
|
| 759 | + 'trad_article_traduction' => 'Tutte le versioni di questo articolo:', |
|
| 760 | + 'trad_delier' => 'Non collegare più a queste traduzioni', # RELIRE |
|
| 761 | + 'trad_lier' => 'Questo articolo è una traduzione dell’articolo numero:', |
|
| 762 | + 'trad_new' => 'Scrivere una nuova traduzione', |
|
| 763 | 763 | |
| 764 | - // U |
|
| 765 | - 'utf8_convert_erreur_orig' => 'Errore: il set di caratteri @charset@ non è supportato.', |
|
| 764 | + // U |
|
| 765 | + 'utf8_convert_erreur_orig' => 'Errore: il set di caratteri @charset@ non è supportato.', |
|
| 766 | 766 | |
| 767 | - // V |
|
| 768 | - 'version' => 'Versione:' |
|
| 767 | + // V |
|
| 768 | + 'version' => 'Versione:' |
|
| 769 | 769 | ); |
@@ -19,7 +19,7 @@ discard block |
||
| 19 | 19 | **/ |
| 20 | 20 | |
| 21 | 21 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 22 | - return; |
|
| 22 | + return; |
|
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | |
@@ -33,16 +33,16 @@ discard block |
||
| 33 | 33 | * @return array|bool|null |
| 34 | 34 | */ |
| 35 | 35 | function quete_virtuel($id_article, $connect) { |
| 36 | - return sql_getfetsel( |
|
| 37 | - 'virtuel', |
|
| 38 | - 'spip_articles', |
|
| 39 | - array('id_article=' . intval($id_article), "statut='publie'"), |
|
| 40 | - '', |
|
| 41 | - '', |
|
| 42 | - '', |
|
| 43 | - '', |
|
| 44 | - $connect |
|
| 45 | - ); |
|
| 36 | + return sql_getfetsel( |
|
| 37 | + 'virtuel', |
|
| 38 | + 'spip_articles', |
|
| 39 | + array('id_article=' . intval($id_article), "statut='publie'"), |
|
| 40 | + '', |
|
| 41 | + '', |
|
| 42 | + '', |
|
| 43 | + '', |
|
| 44 | + $connect |
|
| 45 | + ); |
|
| 46 | 46 | } |
| 47 | 47 | |
| 48 | 48 | /** |
@@ -57,38 +57,38 @@ discard block |
||
| 57 | 57 | * @return array |
| 58 | 58 | */ |
| 59 | 59 | function quete_parent_lang($table, $id, $connect = '') { |
| 60 | - static $cache_quete = array(); |
|
| 61 | - |
|
| 62 | - if (!isset($cache_quete[$connect][$table][$id])) { |
|
| 63 | - if (!isset($cache_quete[$connect][$table]['_select'])) { |
|
| 64 | - $trouver_table = charger_fonction('trouver_table', 'base'); |
|
| 65 | - if (!$desc = $trouver_table($table, |
|
| 66 | - $connect) or !isset($desc['field']['id_rubrique']) |
|
| 67 | - ) { |
|
| 68 | - // pas de parent rubrique, on passe |
|
| 69 | - $cache_quete[$connect][$table]['_select'] = false; |
|
| 70 | - } else { |
|
| 71 | - $select = ($table == 'spip_rubriques' ? 'id_parent' : 'id_rubrique'); |
|
| 72 | - $select .= isset($desc['field']['lang']) ? ', lang' : ''; |
|
| 73 | - $cache_quete[$connect][$table]['_select'] = $select; |
|
| 74 | - $cache_quete[$connect][$table]['_id'] = id_table_objet(objet_type($table)); |
|
| 75 | - } |
|
| 76 | - } |
|
| 77 | - if ($cache_quete[$connect][$table]['_select']) { |
|
| 78 | - $cache_quete[$connect][$table][$id] = sql_fetsel( |
|
| 79 | - $cache_quete[$connect][$table]['_select'], |
|
| 80 | - $table, |
|
| 81 | - $cache_quete[$connect][$table]['_id'] . '=' . intval($id), |
|
| 82 | - '', |
|
| 83 | - '', |
|
| 84 | - '', |
|
| 85 | - '', |
|
| 86 | - $connect |
|
| 87 | - ); |
|
| 88 | - } |
|
| 89 | - } |
|
| 90 | - |
|
| 91 | - return isset($cache_quete[$connect][$table][$id]) ? $cache_quete[$connect][$table][$id] : null; |
|
| 60 | + static $cache_quete = array(); |
|
| 61 | + |
|
| 62 | + if (!isset($cache_quete[$connect][$table][$id])) { |
|
| 63 | + if (!isset($cache_quete[$connect][$table]['_select'])) { |
|
| 64 | + $trouver_table = charger_fonction('trouver_table', 'base'); |
|
| 65 | + if (!$desc = $trouver_table($table, |
|
| 66 | + $connect) or !isset($desc['field']['id_rubrique']) |
|
| 67 | + ) { |
|
| 68 | + // pas de parent rubrique, on passe |
|
| 69 | + $cache_quete[$connect][$table]['_select'] = false; |
|
| 70 | + } else { |
|
| 71 | + $select = ($table == 'spip_rubriques' ? 'id_parent' : 'id_rubrique'); |
|
| 72 | + $select .= isset($desc['field']['lang']) ? ', lang' : ''; |
|
| 73 | + $cache_quete[$connect][$table]['_select'] = $select; |
|
| 74 | + $cache_quete[$connect][$table]['_id'] = id_table_objet(objet_type($table)); |
|
| 75 | + } |
|
| 76 | + } |
|
| 77 | + if ($cache_quete[$connect][$table]['_select']) { |
|
| 78 | + $cache_quete[$connect][$table][$id] = sql_fetsel( |
|
| 79 | + $cache_quete[$connect][$table]['_select'], |
|
| 80 | + $table, |
|
| 81 | + $cache_quete[$connect][$table]['_id'] . '=' . intval($id), |
|
| 82 | + '', |
|
| 83 | + '', |
|
| 84 | + '', |
|
| 85 | + '', |
|
| 86 | + $connect |
|
| 87 | + ); |
|
| 88 | + } |
|
| 89 | + } |
|
| 90 | + |
|
| 91 | + return isset($cache_quete[$connect][$table][$id]) ? $cache_quete[$connect][$table][$id] : null; |
|
| 92 | 92 | } |
| 93 | 93 | |
| 94 | 94 | |
@@ -105,11 +105,11 @@ discard block |
||
| 105 | 105 | * @return int |
| 106 | 106 | */ |
| 107 | 107 | function quete_parent($id_rubrique, $connect = '') { |
| 108 | - if (!$id_rubrique = intval($id_rubrique)) { |
|
| 109 | - return 0; |
|
| 110 | - } |
|
| 111 | - $id_parent = quete_parent_lang('spip_rubriques', $id_rubrique, $connect); |
|
| 112 | - return $id_parent ? $id_parent['id_parent'] : 0; |
|
| 108 | + if (!$id_rubrique = intval($id_rubrique)) { |
|
| 109 | + return 0; |
|
| 110 | + } |
|
| 111 | + $id_parent = quete_parent_lang('spip_rubriques', $id_rubrique, $connect); |
|
| 112 | + return $id_parent ? $id_parent['id_parent'] : 0; |
|
| 113 | 113 | } |
| 114 | 114 | |
| 115 | 115 | /** |
@@ -125,9 +125,9 @@ discard block |
||
| 125 | 125 | * @return int |
| 126 | 126 | */ |
| 127 | 127 | function quete_rubrique($id_article, $serveur) { |
| 128 | - $id_parent = quete_parent_lang('spip_articles', $id_article, $serveur); |
|
| 128 | + $id_parent = quete_parent_lang('spip_articles', $id_article, $serveur); |
|
| 129 | 129 | |
| 130 | - return $id_parent['id_rubrique']; |
|
| 130 | + return $id_parent['id_rubrique']; |
|
| 131 | 131 | } |
| 132 | 132 | |
| 133 | 133 | |
@@ -141,13 +141,13 @@ discard block |
||
| 141 | 141 | * @return int |
| 142 | 142 | */ |
| 143 | 143 | function quete_profondeur($id, $connect = '') { |
| 144 | - $n = 0; |
|
| 145 | - while ($id) { |
|
| 146 | - $n++; |
|
| 147 | - $id = quete_parent($id, $connect); |
|
| 148 | - } |
|
| 144 | + $n = 0; |
|
| 145 | + while ($id) { |
|
| 146 | + $n++; |
|
| 147 | + $id = quete_parent($id, $connect); |
|
| 148 | + } |
|
| 149 | 149 | |
| 150 | - return $n; |
|
| 150 | + return $n; |
|
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | |
@@ -163,15 +163,15 @@ discard block |
||
| 163 | 163 | * Morceau de la requête SQL testant la date |
| 164 | 164 | */ |
| 165 | 165 | function quete_condition_postdates($champ_date, $serveur = '', $ignore_previsu = false) { |
| 166 | - if (defined('_VAR_PREVIEW') and _VAR_PREVIEW and !$ignore_previsu) { |
|
| 167 | - return '1=1'; |
|
| 168 | - } |
|
| 169 | - |
|
| 170 | - return |
|
| 171 | - (isset($GLOBALS['meta']['date_prochain_postdate']) |
|
| 172 | - and $GLOBALS['meta']['date_prochain_postdate'] > time()) |
|
| 173 | - ? "$champ_date<" . sql_quote(date('Y-m-d H:i:s', $GLOBALS['meta']['date_prochain_postdate']), $serveur) |
|
| 174 | - : '1=1'; |
|
| 166 | + if (defined('_VAR_PREVIEW') and _VAR_PREVIEW and !$ignore_previsu) { |
|
| 167 | + return '1=1'; |
|
| 168 | + } |
|
| 169 | + |
|
| 170 | + return |
|
| 171 | + (isset($GLOBALS['meta']['date_prochain_postdate']) |
|
| 172 | + and $GLOBALS['meta']['date_prochain_postdate'] > time()) |
|
| 173 | + ? "$champ_date<" . sql_quote(date('Y-m-d H:i:s', $GLOBALS['meta']['date_prochain_postdate']), $serveur) |
|
| 174 | + : '1=1'; |
|
| 175 | 175 | } |
| 176 | 176 | |
| 177 | 177 | |
@@ -191,100 +191,100 @@ discard block |
||
| 191 | 191 | * @return array|string |
| 192 | 192 | */ |
| 193 | 193 | function quete_condition_statut($mstatut, $previsu, $publie, $serveur = '', $ignore_previsu = false) { |
| 194 | - static $cond = array(); |
|
| 195 | - $key = func_get_args(); |
|
| 196 | - $key = implode('-', $key); |
|
| 197 | - if (isset($cond[$key])) { |
|
| 198 | - return $cond[$key]; |
|
| 199 | - } |
|
| 200 | - |
|
| 201 | - $liste_statuts = $publie; |
|
| 202 | - if (defined('_VAR_PREVIEW') and _VAR_PREVIEW and !$ignore_previsu) { |
|
| 203 | - $liste_statuts = $previsu; |
|
| 204 | - } |
|
| 205 | - $not = false; |
|
| 206 | - if (strncmp($liste_statuts, '!', 1) == 0) { |
|
| 207 | - $not = true; |
|
| 208 | - $liste_statuts = substr($liste_statuts, 1); |
|
| 209 | - } |
|
| 210 | - // '' => ne rien afficher, '!'=> ne rien filtrer |
|
| 211 | - if (!strlen($liste_statuts)) { |
|
| 212 | - return $cond[$key] = ($not ? '1=1' : '0=1'); |
|
| 213 | - } |
|
| 214 | - |
|
| 215 | - $liste_statuts = explode(',', $liste_statuts); |
|
| 216 | - $where = array(); |
|
| 217 | - foreach ($liste_statuts as $k => $v) { |
|
| 218 | - // filtrage /auteur pour limiter les objets d'un statut (prepa en general) |
|
| 219 | - // a ceux de l'auteur identifie |
|
| 220 | - if (strpos($v, '/') !== false) { |
|
| 221 | - $v = explode('/', $v); |
|
| 222 | - $filtre = end($v); |
|
| 223 | - $v = reset($v); |
|
| 224 | - $v = preg_replace(',\W,', '', $v); |
|
| 225 | - if ($filtre == 'auteur' |
|
| 226 | - and (strpos($mstatut, '.') !== false) |
|
| 227 | - and $objet = explode('.', $mstatut) |
|
| 228 | - and $id_table = reset($objet) |
|
| 229 | - and $objet = objet_type($id_table) |
|
| 230 | - ) { |
|
| 231 | - $w = "$mstatut<>" . sql_quote($v); |
|
| 232 | - |
|
| 233 | - // retrouver l’id_auteur qui a filé un lien de prévisu éventuellement, |
|
| 234 | - // sinon l’auteur en session |
|
| 235 | - include_spip('inc/securiser_action'); |
|
| 236 | - if ($desc = decrire_token_previsu()) { |
|
| 237 | - $id_auteur = $desc['id_auteur']; |
|
| 238 | - } elseif (isset($GLOBALS['visiteur_session']['id_auteur'])) { |
|
| 239 | - $id_auteur = intval($GLOBALS['visiteur_session']['id_auteur']); |
|
| 240 | - } else { |
|
| 241 | - $id_auteur = null; |
|
| 242 | - } |
|
| 243 | - |
|
| 244 | - // dans ce cas (admin en general), pas de filtrage sur ce statut |
|
| 245 | - if (!autoriser('previsualiser' . $v, $objet, '', $id_auteur)) { |
|
| 246 | - // si pas d'auteur identifie pas de sous-requete car pas d'article qui matche |
|
| 247 | - if (!$id_auteur) { |
|
| 248 | - $where[] = $w; |
|
| 249 | - } else { |
|
| 250 | - $primary = id_table_objet($objet); |
|
| 251 | - $where[] = "($w OR $id_table.$primary IN (" . sql_get_select( |
|
| 252 | - 'ssss.id_objet', |
|
| 253 | - 'spip_auteurs_liens AS ssss', |
|
| 254 | - 'ssss.objet=' . sql_quote($objet) . ' AND ssss.id_auteur=' . intval($id_auteur), |
|
| 255 | - '', |
|
| 256 | - '', |
|
| 257 | - '', |
|
| 258 | - '', |
|
| 259 | - $serveur |
|
| 260 | - ) . '))'; |
|
| 261 | - } |
|
| 262 | - } |
|
| 263 | - } // ignorer ce statut si on ne sait pas comment le filtrer |
|
| 264 | - else { |
|
| 265 | - $v = ''; |
|
| 266 | - } |
|
| 267 | - } |
|
| 268 | - // securite |
|
| 269 | - $liste_statuts[$k] = preg_replace(',\W,', '', $v); |
|
| 270 | - } |
|
| 271 | - $liste_statuts = array_filter($liste_statuts); |
|
| 272 | - if (count($liste_statuts) == 1) { |
|
| 273 | - $where[] = array('=', $mstatut, sql_quote(reset($liste_statuts), $serveur)); |
|
| 274 | - } else { |
|
| 275 | - $where[] = sql_in($mstatut, $liste_statuts, $not, $serveur); |
|
| 276 | - } |
|
| 277 | - |
|
| 278 | - while (count($where) > 1) { |
|
| 279 | - $and = array('AND', array_pop($where), array_pop($where)); |
|
| 280 | - $where[] = $and; |
|
| 281 | - } |
|
| 282 | - $cond[$key] = reset($where); |
|
| 283 | - if ($not) { |
|
| 284 | - $cond[$key] = array('NOT', $cond[$key]); |
|
| 285 | - } |
|
| 286 | - |
|
| 287 | - return $cond[$key]; |
|
| 194 | + static $cond = array(); |
|
| 195 | + $key = func_get_args(); |
|
| 196 | + $key = implode('-', $key); |
|
| 197 | + if (isset($cond[$key])) { |
|
| 198 | + return $cond[$key]; |
|
| 199 | + } |
|
| 200 | + |
|
| 201 | + $liste_statuts = $publie; |
|
| 202 | + if (defined('_VAR_PREVIEW') and _VAR_PREVIEW and !$ignore_previsu) { |
|
| 203 | + $liste_statuts = $previsu; |
|
| 204 | + } |
|
| 205 | + $not = false; |
|
| 206 | + if (strncmp($liste_statuts, '!', 1) == 0) { |
|
| 207 | + $not = true; |
|
| 208 | + $liste_statuts = substr($liste_statuts, 1); |
|
| 209 | + } |
|
| 210 | + // '' => ne rien afficher, '!'=> ne rien filtrer |
|
| 211 | + if (!strlen($liste_statuts)) { |
|
| 212 | + return $cond[$key] = ($not ? '1=1' : '0=1'); |
|
| 213 | + } |
|
| 214 | + |
|
| 215 | + $liste_statuts = explode(',', $liste_statuts); |
|
| 216 | + $where = array(); |
|
| 217 | + foreach ($liste_statuts as $k => $v) { |
|
| 218 | + // filtrage /auteur pour limiter les objets d'un statut (prepa en general) |
|
| 219 | + // a ceux de l'auteur identifie |
|
| 220 | + if (strpos($v, '/') !== false) { |
|
| 221 | + $v = explode('/', $v); |
|
| 222 | + $filtre = end($v); |
|
| 223 | + $v = reset($v); |
|
| 224 | + $v = preg_replace(',\W,', '', $v); |
|
| 225 | + if ($filtre == 'auteur' |
|
| 226 | + and (strpos($mstatut, '.') !== false) |
|
| 227 | + and $objet = explode('.', $mstatut) |
|
| 228 | + and $id_table = reset($objet) |
|
| 229 | + and $objet = objet_type($id_table) |
|
| 230 | + ) { |
|
| 231 | + $w = "$mstatut<>" . sql_quote($v); |
|
| 232 | + |
|
| 233 | + // retrouver l’id_auteur qui a filé un lien de prévisu éventuellement, |
|
| 234 | + // sinon l’auteur en session |
|
| 235 | + include_spip('inc/securiser_action'); |
|
| 236 | + if ($desc = decrire_token_previsu()) { |
|
| 237 | + $id_auteur = $desc['id_auteur']; |
|
| 238 | + } elseif (isset($GLOBALS['visiteur_session']['id_auteur'])) { |
|
| 239 | + $id_auteur = intval($GLOBALS['visiteur_session']['id_auteur']); |
|
| 240 | + } else { |
|
| 241 | + $id_auteur = null; |
|
| 242 | + } |
|
| 243 | + |
|
| 244 | + // dans ce cas (admin en general), pas de filtrage sur ce statut |
|
| 245 | + if (!autoriser('previsualiser' . $v, $objet, '', $id_auteur)) { |
|
| 246 | + // si pas d'auteur identifie pas de sous-requete car pas d'article qui matche |
|
| 247 | + if (!$id_auteur) { |
|
| 248 | + $where[] = $w; |
|
| 249 | + } else { |
|
| 250 | + $primary = id_table_objet($objet); |
|
| 251 | + $where[] = "($w OR $id_table.$primary IN (" . sql_get_select( |
|
| 252 | + 'ssss.id_objet', |
|
| 253 | + 'spip_auteurs_liens AS ssss', |
|
| 254 | + 'ssss.objet=' . sql_quote($objet) . ' AND ssss.id_auteur=' . intval($id_auteur), |
|
| 255 | + '', |
|
| 256 | + '', |
|
| 257 | + '', |
|
| 258 | + '', |
|
| 259 | + $serveur |
|
| 260 | + ) . '))'; |
|
| 261 | + } |
|
| 262 | + } |
|
| 263 | + } // ignorer ce statut si on ne sait pas comment le filtrer |
|
| 264 | + else { |
|
| 265 | + $v = ''; |
|
| 266 | + } |
|
| 267 | + } |
|
| 268 | + // securite |
|
| 269 | + $liste_statuts[$k] = preg_replace(',\W,', '', $v); |
|
| 270 | + } |
|
| 271 | + $liste_statuts = array_filter($liste_statuts); |
|
| 272 | + if (count($liste_statuts) == 1) { |
|
| 273 | + $where[] = array('=', $mstatut, sql_quote(reset($liste_statuts), $serveur)); |
|
| 274 | + } else { |
|
| 275 | + $where[] = sql_in($mstatut, $liste_statuts, $not, $serveur); |
|
| 276 | + } |
|
| 277 | + |
|
| 278 | + while (count($where) > 1) { |
|
| 279 | + $and = array('AND', array_pop($where), array_pop($where)); |
|
| 280 | + $where[] = $and; |
|
| 281 | + } |
|
| 282 | + $cond[$key] = reset($where); |
|
| 283 | + if ($not) { |
|
| 284 | + $cond[$key] = array('NOT', $cond[$key]); |
|
| 285 | + } |
|
| 286 | + |
|
| 287 | + return $cond[$key]; |
|
| 288 | 288 | } |
| 289 | 289 | |
| 290 | 290 | /** |
@@ -295,7 +295,7 @@ discard block |
||
| 295 | 295 | * @return array|bool|null |
| 296 | 296 | */ |
| 297 | 297 | function quete_fichier($id_document, $serveur = '') { |
| 298 | - return sql_getfetsel('fichier', 'spip_documents', ('id_document=' . intval($id_document)), '', array(), '', '', $serveur); |
|
| 298 | + return sql_getfetsel('fichier', 'spip_documents', ('id_document=' . intval($id_document)), '', array(), '', '', $serveur); |
|
| 299 | 299 | } |
| 300 | 300 | |
| 301 | 301 | /** |
@@ -306,7 +306,7 @@ discard block |
||
| 306 | 306 | * @return array|bool |
| 307 | 307 | */ |
| 308 | 308 | function quete_document($id_document, $serveur = '') { |
| 309 | - return sql_fetsel('*', 'spip_documents', ('id_document=' . intval($id_document)), '', array(), '', '', $serveur); |
|
| 309 | + return sql_fetsel('*', 'spip_documents', ('id_document=' . intval($id_document)), '', array(), '', '', $serveur); |
|
| 310 | 310 | } |
| 311 | 311 | |
| 312 | 312 | /** |
@@ -317,7 +317,7 @@ discard block |
||
| 317 | 317 | * @return array|bool|null |
| 318 | 318 | */ |
| 319 | 319 | function quete_meta($nom, $serveur) { |
| 320 | - return sql_getfetsel('valeur', 'spip_meta', 'nom=' . sql_quote($nom), '', '', '', '', $serveur); |
|
| 320 | + return sql_getfetsel('valeur', 'spip_meta', 'nom=' . sql_quote($nom), '', '', '', '', $serveur); |
|
| 321 | 321 | } |
| 322 | 322 | |
| 323 | 323 | /** |
@@ -343,66 +343,66 @@ discard block |
||
| 343 | 343 | * Retourne soit un tableau, soit le chemin du fichier. |
| 344 | 344 | */ |
| 345 | 345 | function quete_logo($cle_objet, $onoff, $id, $id_rubrique, $flag) { |
| 346 | - include_spip('base/objets'); |
|
| 347 | - $nom = strtolower($onoff); |
|
| 348 | - |
|
| 349 | - $cle_objet = id_table_objet($cle_objet); |
|
| 350 | - |
|
| 351 | - while (1) { |
|
| 352 | - $objet = objet_type($cle_objet); |
|
| 353 | - |
|
| 354 | - $on = quete_logo_objet($id, $objet, $nom); |
|
| 355 | - |
|
| 356 | - if ($on) { |
|
| 357 | - if ($flag) { |
|
| 358 | - return basename($on['chemin']); |
|
| 359 | - } else { |
|
| 360 | - $taille = @spip_getimagesize($on['chemin']); |
|
| 361 | - |
|
| 362 | - // Si on a déjà demandé un survol directement ($onoff = off) |
|
| 363 | - // ou qu'on a demandé uniquement le normal ($onoff = on) |
|
| 364 | - // alors on ne cherche pas du tout le survol ici |
|
| 365 | - if ($onoff != 'ON') { |
|
| 366 | - $off = ''; |
|
| 367 | - } else { |
|
| 368 | - // Sinon, c'est qu'on demande normal ET survol à la fois, donc on cherche maintenant le survol |
|
| 369 | - $off = quete_logo_objet($id, $objet, 'off'); |
|
| 370 | - } |
|
| 371 | - |
|
| 372 | - // on retourne une url du type IMG/artonXX?timestamp |
|
| 373 | - // qui permet de distinguer le changement de logo |
|
| 374 | - // et placer un expire sur le dossier IMG/ |
|
| 375 | - $res = array( |
|
| 376 | - $on['chemin'] . ($on['timestamp'] ? "?{$on['timestamp']}" : ''), |
|
| 377 | - ($off ? $off['chemin'] . ($off['timestamp'] ? "?{$off['timestamp']}" : '') : ''), |
|
| 378 | - (!$taille ? '' : (' ' . $taille[3])) |
|
| 379 | - ); |
|
| 380 | - $res['src'] = $res[0]; |
|
| 381 | - $res['logo_on'] = $res[0]; |
|
| 382 | - $res['logo_off'] = $res[1]; |
|
| 383 | - $res['width'] = ($taille ? $taille[0] : ''); |
|
| 384 | - $res['height'] = ($taille ? $taille[1] : ''); |
|
| 385 | - |
|
| 386 | - return $res; |
|
| 387 | - } |
|
| 388 | - } else { |
|
| 389 | - if (defined('_LOGO_RUBRIQUE_DESACTIVER_HERITAGE')) { |
|
| 390 | - return ''; |
|
| 391 | - } else { |
|
| 392 | - if ($id_rubrique) { |
|
| 393 | - $cle_objet = 'id_rubrique'; |
|
| 394 | - $id = $id_rubrique; |
|
| 395 | - $id_rubrique = 0; |
|
| 396 | - } else { |
|
| 397 | - if ($id and $cle_objet == 'id_rubrique') { |
|
| 398 | - $id = quete_parent($id); |
|
| 399 | - } else { |
|
| 400 | - return ''; |
|
| 401 | - } |
|
| 402 | - } |
|
| 403 | - } |
|
| 404 | - } |
|
| 405 | - } |
|
| 346 | + include_spip('base/objets'); |
|
| 347 | + $nom = strtolower($onoff); |
|
| 348 | + |
|
| 349 | + $cle_objet = id_table_objet($cle_objet); |
|
| 350 | + |
|
| 351 | + while (1) { |
|
| 352 | + $objet = objet_type($cle_objet); |
|
| 353 | + |
|
| 354 | + $on = quete_logo_objet($id, $objet, $nom); |
|
| 355 | + |
|
| 356 | + if ($on) { |
|
| 357 | + if ($flag) { |
|
| 358 | + return basename($on['chemin']); |
|
| 359 | + } else { |
|
| 360 | + $taille = @spip_getimagesize($on['chemin']); |
|
| 361 | + |
|
| 362 | + // Si on a déjà demandé un survol directement ($onoff = off) |
|
| 363 | + // ou qu'on a demandé uniquement le normal ($onoff = on) |
|
| 364 | + // alors on ne cherche pas du tout le survol ici |
|
| 365 | + if ($onoff != 'ON') { |
|
| 366 | + $off = ''; |
|
| 367 | + } else { |
|
| 368 | + // Sinon, c'est qu'on demande normal ET survol à la fois, donc on cherche maintenant le survol |
|
| 369 | + $off = quete_logo_objet($id, $objet, 'off'); |
|
| 370 | + } |
|
| 371 | + |
|
| 372 | + // on retourne une url du type IMG/artonXX?timestamp |
|
| 373 | + // qui permet de distinguer le changement de logo |
|
| 374 | + // et placer un expire sur le dossier IMG/ |
|
| 375 | + $res = array( |
|
| 376 | + $on['chemin'] . ($on['timestamp'] ? "?{$on['timestamp']}" : ''), |
|
| 377 | + ($off ? $off['chemin'] . ($off['timestamp'] ? "?{$off['timestamp']}" : '') : ''), |
|
| 378 | + (!$taille ? '' : (' ' . $taille[3])) |
|
| 379 | + ); |
|
| 380 | + $res['src'] = $res[0]; |
|
| 381 | + $res['logo_on'] = $res[0]; |
|
| 382 | + $res['logo_off'] = $res[1]; |
|
| 383 | + $res['width'] = ($taille ? $taille[0] : ''); |
|
| 384 | + $res['height'] = ($taille ? $taille[1] : ''); |
|
| 385 | + |
|
| 386 | + return $res; |
|
| 387 | + } |
|
| 388 | + } else { |
|
| 389 | + if (defined('_LOGO_RUBRIQUE_DESACTIVER_HERITAGE')) { |
|
| 390 | + return ''; |
|
| 391 | + } else { |
|
| 392 | + if ($id_rubrique) { |
|
| 393 | + $cle_objet = 'id_rubrique'; |
|
| 394 | + $id = $id_rubrique; |
|
| 395 | + $id_rubrique = 0; |
|
| 396 | + } else { |
|
| 397 | + if ($id and $cle_objet == 'id_rubrique') { |
|
| 398 | + $id = quete_parent($id); |
|
| 399 | + } else { |
|
| 400 | + return ''; |
|
| 401 | + } |
|
| 402 | + } |
|
| 403 | + } |
|
| 404 | + } |
|
| 405 | + } |
|
| 406 | 406 | } |
| 407 | 407 | |
| 408 | 408 | /** |
@@ -416,37 +416,37 @@ discard block |
||
| 416 | 416 | * "on" ou "off" suivant le logo normal ou survol |
| 417 | 417 | **/ |
| 418 | 418 | function quete_logo_objet($id_objet, $objet, $mode) { |
| 419 | - static $chercher_logo; |
|
| 420 | - if (is_null($chercher_logo)) { |
|
| 421 | - $chercher_logo = charger_fonction('chercher_logo', 'inc'); |
|
| 422 | - } |
|
| 423 | - $cle_objet = id_table_objet($objet); |
|
| 424 | - |
|
| 425 | - // On cherche pas la méthode classique |
|
| 426 | - $infos_logo = $chercher_logo($id_objet, $cle_objet, $mode); |
|
| 427 | - // Si la méthode classique a trouvé quelque chose, on utilise le nouveau format |
|
| 428 | - if (!empty($infos_logo)) { |
|
| 429 | - $infos_logo = array( |
|
| 430 | - 'chemin' => $infos_logo[0], |
|
| 431 | - 'timestamp' => $infos_logo[4], |
|
| 432 | - ); |
|
| 433 | - } |
|
| 434 | - |
|
| 435 | - // On passe cette recherche de logo dans un pipeline |
|
| 436 | - $infos_logo = pipeline( |
|
| 437 | - 'quete_logo_objet', |
|
| 438 | - array( |
|
| 439 | - 'args' => array( |
|
| 440 | - 'id_objet' => $id_objet, |
|
| 441 | - 'objet' => $objet, |
|
| 442 | - 'cle_objet' => $cle_objet, |
|
| 443 | - 'mode' => $mode, |
|
| 444 | - ), |
|
| 445 | - 'data' => $infos_logo, |
|
| 446 | - ) |
|
| 447 | - ); |
|
| 448 | - |
|
| 449 | - return $infos_logo; |
|
| 419 | + static $chercher_logo; |
|
| 420 | + if (is_null($chercher_logo)) { |
|
| 421 | + $chercher_logo = charger_fonction('chercher_logo', 'inc'); |
|
| 422 | + } |
|
| 423 | + $cle_objet = id_table_objet($objet); |
|
| 424 | + |
|
| 425 | + // On cherche pas la méthode classique |
|
| 426 | + $infos_logo = $chercher_logo($id_objet, $cle_objet, $mode); |
|
| 427 | + // Si la méthode classique a trouvé quelque chose, on utilise le nouveau format |
|
| 428 | + if (!empty($infos_logo)) { |
|
| 429 | + $infos_logo = array( |
|
| 430 | + 'chemin' => $infos_logo[0], |
|
| 431 | + 'timestamp' => $infos_logo[4], |
|
| 432 | + ); |
|
| 433 | + } |
|
| 434 | + |
|
| 435 | + // On passe cette recherche de logo dans un pipeline |
|
| 436 | + $infos_logo = pipeline( |
|
| 437 | + 'quete_logo_objet', |
|
| 438 | + array( |
|
| 439 | + 'args' => array( |
|
| 440 | + 'id_objet' => $id_objet, |
|
| 441 | + 'objet' => $objet, |
|
| 442 | + 'cle_objet' => $cle_objet, |
|
| 443 | + 'mode' => $mode, |
|
| 444 | + ), |
|
| 445 | + 'data' => $infos_logo, |
|
| 446 | + ) |
|
| 447 | + ); |
|
| 448 | + |
|
| 449 | + return $infos_logo; |
|
| 450 | 450 | } |
| 451 | 451 | |
| 452 | 452 | /** |
@@ -459,24 +459,24 @@ discard block |
||
| 459 | 459 | * @return bool|string |
| 460 | 460 | */ |
| 461 | 461 | function quete_logo_file($row, $connect = null) { |
| 462 | - include_spip('inc/documents'); |
|
| 463 | - $logo = vignette_logo_document($row, $connect); |
|
| 464 | - if (!$logo) { |
|
| 465 | - $logo = image_du_document($row, $connect); |
|
| 466 | - } |
|
| 467 | - if (!$logo) { |
|
| 468 | - $f = charger_fonction('vignette', 'inc'); |
|
| 469 | - $logo = $f($row['extension'], false); |
|
| 470 | - } |
|
| 471 | - // si c'est une vignette type doc, la renvoyer direct |
|
| 472 | - if (strcmp($logo, _DIR_PLUGINS) == 0 |
|
| 473 | - or strcmp($logo, _DIR_PLUGINS_DIST) == 0 |
|
| 474 | - or strcmp($logo, _DIR_RACINE . 'prive/') == 0 |
|
| 475 | - ) { |
|
| 476 | - return $logo; |
|
| 477 | - } |
|
| 478 | - |
|
| 479 | - return get_spip_doc($logo); |
|
| 462 | + include_spip('inc/documents'); |
|
| 463 | + $logo = vignette_logo_document($row, $connect); |
|
| 464 | + if (!$logo) { |
|
| 465 | + $logo = image_du_document($row, $connect); |
|
| 466 | + } |
|
| 467 | + if (!$logo) { |
|
| 468 | + $f = charger_fonction('vignette', 'inc'); |
|
| 469 | + $logo = $f($row['extension'], false); |
|
| 470 | + } |
|
| 471 | + // si c'est une vignette type doc, la renvoyer direct |
|
| 472 | + if (strcmp($logo, _DIR_PLUGINS) == 0 |
|
| 473 | + or strcmp($logo, _DIR_PLUGINS_DIST) == 0 |
|
| 474 | + or strcmp($logo, _DIR_RACINE . 'prive/') == 0 |
|
| 475 | + ) { |
|
| 476 | + return $logo; |
|
| 477 | + } |
|
| 478 | + |
|
| 479 | + return get_spip_doc($logo); |
|
| 480 | 480 | } |
| 481 | 481 | |
| 482 | 482 | /** |
@@ -504,20 +504,20 @@ discard block |
||
| 504 | 504 | */ |
| 505 | 505 | function quete_logo_document($row, $lien, $align, $mode_logo, $x, $y, $connect = null) { |
| 506 | 506 | |
| 507 | - include_spip('inc/documents'); |
|
| 508 | - $logo = ''; |
|
| 509 | - if (!in_array($mode_logo, array('icone', 'apercu'))) { |
|
| 510 | - $logo = vignette_logo_document($row, $connect); |
|
| 511 | - } |
|
| 512 | - // si on veut explicitement la vignette, ne rien renvoyer si il n'y en a pas |
|
| 513 | - if ($mode_logo == 'vignette' and !$logo) { |
|
| 514 | - return ''; |
|
| 515 | - } |
|
| 516 | - if ($mode_logo == 'icone') { |
|
| 517 | - $row['fichier'] = ''; |
|
| 518 | - } |
|
| 519 | - |
|
| 520 | - return vignette_automatique($logo, $row, $lien, $x, $y, $align, null, $connect); |
|
| 507 | + include_spip('inc/documents'); |
|
| 508 | + $logo = ''; |
|
| 509 | + if (!in_array($mode_logo, array('icone', 'apercu'))) { |
|
| 510 | + $logo = vignette_logo_document($row, $connect); |
|
| 511 | + } |
|
| 512 | + // si on veut explicitement la vignette, ne rien renvoyer si il n'y en a pas |
|
| 513 | + if ($mode_logo == 'vignette' and !$logo) { |
|
| 514 | + return ''; |
|
| 515 | + } |
|
| 516 | + if ($mode_logo == 'icone') { |
|
| 517 | + $row['fichier'] = ''; |
|
| 518 | + } |
|
| 519 | + |
|
| 520 | + return vignette_automatique($logo, $row, $lien, $x, $y, $align, null, $connect); |
|
| 521 | 521 | } |
| 522 | 522 | |
| 523 | 523 | /** |
@@ -529,19 +529,19 @@ discard block |
||
| 529 | 529 | */ |
| 530 | 530 | function quete_html_logo($logo, $align, $lien) { |
| 531 | 531 | |
| 532 | - if (!is_array($logo)) { |
|
| 533 | - return ''; |
|
| 534 | - } |
|
| 535 | - |
|
| 536 | - $contexte = []; |
|
| 537 | - foreach ($logo as $k=>$v) { |
|
| 538 | - if (!is_numeric($k)) { |
|
| 539 | - $contexte[$k] = $v; |
|
| 540 | - } |
|
| 541 | - } |
|
| 542 | - $contexte['align'] = $align; |
|
| 543 | - $contexte['lien'] = $lien; |
|
| 544 | - return recuperer_fond('modeles/logo', $contexte); |
|
| 532 | + if (!is_array($logo)) { |
|
| 533 | + return ''; |
|
| 534 | + } |
|
| 535 | + |
|
| 536 | + $contexte = []; |
|
| 537 | + foreach ($logo as $k=>$v) { |
|
| 538 | + if (!is_numeric($k)) { |
|
| 539 | + $contexte[$k] = $v; |
|
| 540 | + } |
|
| 541 | + } |
|
| 542 | + $contexte['align'] = $align; |
|
| 543 | + $contexte['lien'] = $lien; |
|
| 544 | + return recuperer_fond('modeles/logo', $contexte); |
|
| 545 | 545 | } |
| 546 | 546 | |
| 547 | 547 | /** |
@@ -555,14 +555,14 @@ discard block |
||
| 555 | 555 | * @return string|false |
| 556 | 556 | */ |
| 557 | 557 | function document_spip_externe($fichier, $connect) { |
| 558 | - if ($connect) { |
|
| 559 | - $site = quete_meta('adresse_site', $connect); |
|
| 560 | - if ($site) { |
|
| 561 | - $dir = quete_meta('dir_img', $connect); |
|
| 562 | - return "$site/$dir$fichier"; |
|
| 563 | - } |
|
| 564 | - } |
|
| 565 | - return false; |
|
| 558 | + if ($connect) { |
|
| 559 | + $site = quete_meta('adresse_site', $connect); |
|
| 560 | + if ($site) { |
|
| 561 | + $dir = quete_meta('dir_img', $connect); |
|
| 562 | + return "$site/$dir$fichier"; |
|
| 563 | + } |
|
| 564 | + } |
|
| 565 | + return false; |
|
| 566 | 566 | } |
| 567 | 567 | |
| 568 | 568 | /** |
@@ -575,23 +575,23 @@ discard block |
||
| 575 | 575 | * @return string |
| 576 | 576 | */ |
| 577 | 577 | function vignette_logo_document($row, $connect = '') { |
| 578 | - if (!$row['id_vignette']) { |
|
| 579 | - return ''; |
|
| 580 | - } |
|
| 581 | - $fichier = quete_fichier($row['id_vignette'], $connect); |
|
| 582 | - if ($url = document_spip_externe($fichier, $connect)) { |
|
| 583 | - return $url; |
|
| 584 | - } |
|
| 585 | - |
|
| 586 | - $f = get_spip_doc($fichier); |
|
| 587 | - if ($f and @file_exists($f)) { |
|
| 588 | - return $f; |
|
| 589 | - } |
|
| 590 | - if ($row['mode'] !== 'vignette') { |
|
| 591 | - return ''; |
|
| 592 | - } |
|
| 593 | - |
|
| 594 | - return generer_url_entite($row['id_document'], 'document', '', '', $connect); |
|
| 578 | + if (!$row['id_vignette']) { |
|
| 579 | + return ''; |
|
| 580 | + } |
|
| 581 | + $fichier = quete_fichier($row['id_vignette'], $connect); |
|
| 582 | + if ($url = document_spip_externe($fichier, $connect)) { |
|
| 583 | + return $url; |
|
| 584 | + } |
|
| 585 | + |
|
| 586 | + $f = get_spip_doc($fichier); |
|
| 587 | + if ($f and @file_exists($f)) { |
|
| 588 | + return $f; |
|
| 589 | + } |
|
| 590 | + if ($row['mode'] !== 'vignette') { |
|
| 591 | + return ''; |
|
| 592 | + } |
|
| 593 | + |
|
| 594 | + return generer_url_entite($row['id_document'], 'document', '', '', $connect); |
|
| 595 | 595 | } |
| 596 | 596 | |
| 597 | 597 | /** |
@@ -607,68 +607,68 @@ discard block |
||
| 607 | 607 | * @return bool|string |
| 608 | 608 | */ |
| 609 | 609 | function calcul_exposer($id, $prim, $reference, $parent, $type, $connect = '') { |
| 610 | - static $exposer = array(); |
|
| 611 | - |
|
| 612 | - // Que faut-il exposer ? Tous les elements de $reference |
|
| 613 | - // ainsi que leur hierarchie ; on ne fait donc ce calcul |
|
| 614 | - // qu'une fois (par squelette) et on conserve le resultat |
|
| 615 | - // en static. |
|
| 616 | - if (!isset($exposer[$m = md5(serialize($reference))][$prim])) { |
|
| 617 | - $principal = isset($reference[$type]) ? $reference[$type] : |
|
| 618 | - // cas de la pagination indecte @xx qui positionne la page avec l'id xx |
|
| 619 | - // et donne la reference dynamique @type=xx dans le contexte |
|
| 620 | - (isset($reference["@$type"]) ? $reference["@$type"] : ''); |
|
| 621 | - // le parent fournit en argument est le parent de $id, pas celui de $principal |
|
| 622 | - // il n'est donc pas utile |
|
| 623 | - $parent = 0; |
|
| 624 | - if (!$principal) { // regarder si un enfant est dans le contexte, auquel cas il expose peut etre le parent courant |
|
| 625 | - $enfants = array('id_rubrique' => array('id_article'), 'id_groupe' => array('id_mot')); |
|
| 626 | - if (isset($enfants[$type])) { |
|
| 627 | - foreach ($enfants[$type] as $t) { |
|
| 628 | - if (isset($reference[$t]) |
|
| 629 | - // cas de la reference donnee dynamiquement par la pagination |
|
| 630 | - or isset($reference["@$t"]) |
|
| 631 | - ) { |
|
| 632 | - $type = $t; |
|
| 633 | - $principal = isset($reference[$type]) ? $reference[$type] : $reference["@$type"]; |
|
| 634 | - continue; |
|
| 635 | - } |
|
| 636 | - } |
|
| 637 | - } |
|
| 638 | - } |
|
| 639 | - $exposer[$m][$type] = array(); |
|
| 640 | - if ($principal) { |
|
| 641 | - $principaux = is_array($principal) ? $principal : array($principal); |
|
| 642 | - foreach ($principaux as $principal) { |
|
| 643 | - $exposer[$m][$type][$principal] = true; |
|
| 644 | - if ($type == 'id_mot') { |
|
| 645 | - if (!$parent) { |
|
| 646 | - $parent = sql_getfetsel('id_groupe', 'spip_mots', 'id_mot=' . intval($principal), '', '', '', '', $connect); |
|
| 647 | - } |
|
| 648 | - if ($parent) { |
|
| 649 | - $exposer[$m]['id_groupe'][$parent] = true; |
|
| 650 | - } |
|
| 651 | - } else { |
|
| 652 | - if ($type != 'id_groupe') { |
|
| 653 | - if (!$parent) { |
|
| 654 | - if ($type == 'id_rubrique') { |
|
| 655 | - $parent = $principal; |
|
| 656 | - } |
|
| 657 | - if ($type == 'id_article') { |
|
| 658 | - $parent = quete_rubrique($principal, $connect); |
|
| 659 | - } |
|
| 660 | - } |
|
| 661 | - do { |
|
| 662 | - $exposer[$m]['id_rubrique'][$parent] = true; |
|
| 663 | - } while ($parent = quete_parent($parent, $connect)); |
|
| 664 | - } |
|
| 665 | - } |
|
| 666 | - } |
|
| 667 | - } |
|
| 668 | - } |
|
| 669 | - |
|
| 670 | - // And the winner is... |
|
| 671 | - return isset($exposer[$m][$prim]) ? isset($exposer[$m][$prim][$id]) : ''; |
|
| 610 | + static $exposer = array(); |
|
| 611 | + |
|
| 612 | + // Que faut-il exposer ? Tous les elements de $reference |
|
| 613 | + // ainsi que leur hierarchie ; on ne fait donc ce calcul |
|
| 614 | + // qu'une fois (par squelette) et on conserve le resultat |
|
| 615 | + // en static. |
|
| 616 | + if (!isset($exposer[$m = md5(serialize($reference))][$prim])) { |
|
| 617 | + $principal = isset($reference[$type]) ? $reference[$type] : |
|
| 618 | + // cas de la pagination indecte @xx qui positionne la page avec l'id xx |
|
| 619 | + // et donne la reference dynamique @type=xx dans le contexte |
|
| 620 | + (isset($reference["@$type"]) ? $reference["@$type"] : ''); |
|
| 621 | + // le parent fournit en argument est le parent de $id, pas celui de $principal |
|
| 622 | + // il n'est donc pas utile |
|
| 623 | + $parent = 0; |
|
| 624 | + if (!$principal) { // regarder si un enfant est dans le contexte, auquel cas il expose peut etre le parent courant |
|
| 625 | + $enfants = array('id_rubrique' => array('id_article'), 'id_groupe' => array('id_mot')); |
|
| 626 | + if (isset($enfants[$type])) { |
|
| 627 | + foreach ($enfants[$type] as $t) { |
|
| 628 | + if (isset($reference[$t]) |
|
| 629 | + // cas de la reference donnee dynamiquement par la pagination |
|
| 630 | + or isset($reference["@$t"]) |
|
| 631 | + ) { |
|
| 632 | + $type = $t; |
|
| 633 | + $principal = isset($reference[$type]) ? $reference[$type] : $reference["@$type"]; |
|
| 634 | + continue; |
|
| 635 | + } |
|
| 636 | + } |
|
| 637 | + } |
|
| 638 | + } |
|
| 639 | + $exposer[$m][$type] = array(); |
|
| 640 | + if ($principal) { |
|
| 641 | + $principaux = is_array($principal) ? $principal : array($principal); |
|
| 642 | + foreach ($principaux as $principal) { |
|
| 643 | + $exposer[$m][$type][$principal] = true; |
|
| 644 | + if ($type == 'id_mot') { |
|
| 645 | + if (!$parent) { |
|
| 646 | + $parent = sql_getfetsel('id_groupe', 'spip_mots', 'id_mot=' . intval($principal), '', '', '', '', $connect); |
|
| 647 | + } |
|
| 648 | + if ($parent) { |
|
| 649 | + $exposer[$m]['id_groupe'][$parent] = true; |
|
| 650 | + } |
|
| 651 | + } else { |
|
| 652 | + if ($type != 'id_groupe') { |
|
| 653 | + if (!$parent) { |
|
| 654 | + if ($type == 'id_rubrique') { |
|
| 655 | + $parent = $principal; |
|
| 656 | + } |
|
| 657 | + if ($type == 'id_article') { |
|
| 658 | + $parent = quete_rubrique($principal, $connect); |
|
| 659 | + } |
|
| 660 | + } |
|
| 661 | + do { |
|
| 662 | + $exposer[$m]['id_rubrique'][$parent] = true; |
|
| 663 | + } while ($parent = quete_parent($parent, $connect)); |
|
| 664 | + } |
|
| 665 | + } |
|
| 666 | + } |
|
| 667 | + } |
|
| 668 | + } |
|
| 669 | + |
|
| 670 | + // And the winner is... |
|
| 671 | + return isset($exposer[$m][$prim]) ? isset($exposer[$m][$prim][$id]) : ''; |
|
| 672 | 672 | } |
| 673 | 673 | |
| 674 | 674 | /** |
@@ -683,21 +683,21 @@ discard block |
||
| 683 | 683 | * @return int |
| 684 | 684 | */ |
| 685 | 685 | function quete_debut_pagination($primary, $valeur, $pas, $iter) { |
| 686 | - // on ne devrait pas arriver ici si la cle primaire est inexistante |
|
| 687 | - // ou composee, mais verifions |
|
| 688 | - if (!$primary or preg_match('/[,\s]/', $primary)) { |
|
| 689 | - return 0; |
|
| 690 | - } |
|
| 691 | - |
|
| 692 | - $pos = 0; |
|
| 693 | - while ($row = $iter->fetch() and $row[$primary] != $valeur) { |
|
| 694 | - $pos++; |
|
| 695 | - } |
|
| 696 | - // si on a pas trouve |
|
| 697 | - if (!$row or $row[$primary] != $valeur) { |
|
| 698 | - return 0; |
|
| 699 | - } |
|
| 700 | - |
|
| 701 | - // sinon, calculer le bon numero de page |
|
| 702 | - return floor($pos / $pas) * $pas; |
|
| 686 | + // on ne devrait pas arriver ici si la cle primaire est inexistante |
|
| 687 | + // ou composee, mais verifions |
|
| 688 | + if (!$primary or preg_match('/[,\s]/', $primary)) { |
|
| 689 | + return 0; |
|
| 690 | + } |
|
| 691 | + |
|
| 692 | + $pos = 0; |
|
| 693 | + while ($row = $iter->fetch() and $row[$primary] != $valeur) { |
|
| 694 | + $pos++; |
|
| 695 | + } |
|
| 696 | + // si on a pas trouve |
|
| 697 | + if (!$row or $row[$primary] != $valeur) { |
|
| 698 | + return 0; |
|
| 699 | + } |
|
| 700 | + |
|
| 701 | + // sinon, calculer le bon numero de page |
|
| 702 | + return floor($pos / $pas) * $pas; |
|
| 703 | 703 | } |
@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | **/ |
| 18 | 18 | |
| 19 | 19 | if (!defined('_ECRIRE_INC_VERSION')) { |
| 20 | - return; |
|
| 20 | + return; |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | * @return void |
| 29 | 29 | */ |
| 30 | 30 | function inc_config_dist() { |
| 31 | - actualise_metas(liste_metas()); |
|
| 31 | + actualise_metas(liste_metas()); |
|
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | /** |
@@ -45,34 +45,34 @@ discard block |
||
| 45 | 45 | * Liste (table, casier, sous_casier) |
| 46 | 46 | */ |
| 47 | 47 | function expliquer_config($cfg) { |
| 48 | - // par defaut, sur la table des meta |
|
| 49 | - $table = 'meta'; |
|
| 50 | - $casier = null; |
|
| 51 | - $sous_casier = array(); |
|
| 52 | - $cfg = explode('/', $cfg); |
|
| 53 | - |
|
| 54 | - // si le premier argument est vide, c'est une syntaxe /table/ ou un appel vide '' |
|
| 55 | - if (!reset($cfg) and count($cfg) > 1) { |
|
| 56 | - array_shift($cfg); |
|
| 57 | - $table = array_shift($cfg); |
|
| 58 | - if (!isset($GLOBALS[$table])) { |
|
| 59 | - lire_metas($table); |
|
| 60 | - } |
|
| 61 | - } |
|
| 62 | - |
|
| 63 | - // si on a demande #CONFIG{/meta,'',0} |
|
| 64 | - if (count($cfg)) { |
|
| 65 | - // pas sur un appel vide '' |
|
| 66 | - if ('' !== ($c = array_shift($cfg))) { |
|
| 67 | - $casier = $c; |
|
| 68 | - } |
|
| 69 | - } |
|
| 70 | - |
|
| 71 | - if (count($cfg)) { |
|
| 72 | - $sous_casier = $cfg; |
|
| 73 | - } |
|
| 74 | - |
|
| 75 | - return array($table, $casier, $sous_casier); |
|
| 48 | + // par defaut, sur la table des meta |
|
| 49 | + $table = 'meta'; |
|
| 50 | + $casier = null; |
|
| 51 | + $sous_casier = array(); |
|
| 52 | + $cfg = explode('/', $cfg); |
|
| 53 | + |
|
| 54 | + // si le premier argument est vide, c'est une syntaxe /table/ ou un appel vide '' |
|
| 55 | + if (!reset($cfg) and count($cfg) > 1) { |
|
| 56 | + array_shift($cfg); |
|
| 57 | + $table = array_shift($cfg); |
|
| 58 | + if (!isset($GLOBALS[$table])) { |
|
| 59 | + lire_metas($table); |
|
| 60 | + } |
|
| 61 | + } |
|
| 62 | + |
|
| 63 | + // si on a demande #CONFIG{/meta,'',0} |
|
| 64 | + if (count($cfg)) { |
|
| 65 | + // pas sur un appel vide '' |
|
| 66 | + if ('' !== ($c = array_shift($cfg))) { |
|
| 67 | + $casier = $c; |
|
| 68 | + } |
|
| 69 | + } |
|
| 70 | + |
|
| 71 | + if (count($cfg)) { |
|
| 72 | + $sous_casier = $cfg; |
|
| 73 | + } |
|
| 74 | + |
|
| 75 | + return array($table, $casier, $sous_casier); |
|
| 76 | 76 | } |
| 77 | 77 | |
| 78 | 78 | /** |
@@ -100,65 +100,65 @@ discard block |
||
| 100 | 100 | * Contenu de la configuration obtenue |
| 101 | 101 | */ |
| 102 | 102 | function lire_config($cfg = '', $def = null, $unserialize = true) { |
| 103 | - // lire le stockage sous la forme /table/valeur |
|
| 104 | - // ou valeur qui est en fait implicitement /meta/valeur |
|
| 105 | - // ou casier/valeur qui est en fait implicitement /meta/casier/valeur |
|
| 106 | - |
|
| 107 | - // traiter en priorite le cas simple et frequent |
|
| 108 | - // de lecture direct $GLOBALS['meta']['truc'], si $cfg ne contient ni / ni : |
|
| 109 | - if ($cfg and strpbrk($cfg, '/:') === false) { |
|
| 110 | - $r = isset($GLOBALS['meta'][$cfg]) ? |
|
| 111 | - ((!$unserialize |
|
| 112 | - // ne pas essayer de deserialiser autre chose qu'une chaine |
|
| 113 | - or !is_string($GLOBALS['meta'][$cfg]) |
|
| 114 | - // ne pas essayer de deserialiser si ce n'est visiblement pas une chaine serializee |
|
| 115 | - or strpos($GLOBALS['meta'][$cfg], ':') === false |
|
| 116 | - or ($t = @unserialize($GLOBALS['meta'][$cfg])) === false) ? $GLOBALS['meta'][$cfg] : $t) |
|
| 117 | - : $def; |
|
| 118 | - |
|
| 119 | - return $r; |
|
| 120 | - } |
|
| 121 | - |
|
| 122 | - // Brancher sur methodes externes si besoin |
|
| 123 | - if ($cfg and $p = strpos($cfg, '::')) { |
|
| 124 | - $methode = substr($cfg, 0, $p); |
|
| 125 | - $lire_config = charger_fonction($methode, 'lire_config'); |
|
| 126 | - |
|
| 127 | - return $lire_config(substr($cfg, $p + 2), $def, $unserialize); |
|
| 128 | - } |
|
| 129 | - |
|
| 130 | - list($table, $casier, $sous_casier) = expliquer_config($cfg); |
|
| 131 | - |
|
| 132 | - if (!isset($GLOBALS[$table])) { |
|
| 133 | - return $def; |
|
| 134 | - } |
|
| 135 | - |
|
| 136 | - $r = $GLOBALS[$table]; |
|
| 137 | - |
|
| 138 | - // si on a demande #CONFIG{/meta,'',0} |
|
| 139 | - if (!$casier) { |
|
| 140 | - return $unserialize ? $r : serialize($r); |
|
| 141 | - } |
|
| 142 | - |
|
| 143 | - // casier principal : |
|
| 144 | - // le deserializer si demande |
|
| 145 | - // ou si on a besoin |
|
| 146 | - // d'un sous casier |
|
| 147 | - $r = isset($r[$casier]) ? $r[$casier] : null; |
|
| 148 | - if (($unserialize or count($sous_casier)) and $r and is_string($r)) { |
|
| 149 | - $r = (($t = @unserialize($r)) === false ? $r : $t); |
|
| 150 | - } |
|
| 151 | - |
|
| 152 | - // aller chercher le sous_casier |
|
| 153 | - while (!is_null($r) and $casier = array_shift($sous_casier)) { |
|
| 154 | - $r = isset($r[$casier]) ? $r[$casier] : null; |
|
| 155 | - } |
|
| 156 | - |
|
| 157 | - if (is_null($r)) { |
|
| 158 | - return $def; |
|
| 159 | - } |
|
| 160 | - |
|
| 161 | - return $r; |
|
| 103 | + // lire le stockage sous la forme /table/valeur |
|
| 104 | + // ou valeur qui est en fait implicitement /meta/valeur |
|
| 105 | + // ou casier/valeur qui est en fait implicitement /meta/casier/valeur |
|
| 106 | + |
|
| 107 | + // traiter en priorite le cas simple et frequent |
|
| 108 | + // de lecture direct $GLOBALS['meta']['truc'], si $cfg ne contient ni / ni : |
|
| 109 | + if ($cfg and strpbrk($cfg, '/:') === false) { |
|
| 110 | + $r = isset($GLOBALS['meta'][$cfg]) ? |
|
| 111 | + ((!$unserialize |
|
| 112 | + // ne pas essayer de deserialiser autre chose qu'une chaine |
|
| 113 | + or !is_string($GLOBALS['meta'][$cfg]) |
|
| 114 | + // ne pas essayer de deserialiser si ce n'est visiblement pas une chaine serializee |
|
| 115 | + or strpos($GLOBALS['meta'][$cfg], ':') === false |
|
| 116 | + or ($t = @unserialize($GLOBALS['meta'][$cfg])) === false) ? $GLOBALS['meta'][$cfg] : $t) |
|
| 117 | + : $def; |
|
| 118 | + |
|
| 119 | + return $r; |
|
| 120 | + } |
|
| 121 | + |
|
| 122 | + // Brancher sur methodes externes si besoin |
|
| 123 | + if ($cfg and $p = strpos($cfg, '::')) { |
|
| 124 | + $methode = substr($cfg, 0, $p); |
|
| 125 | + $lire_config = charger_fonction($methode, 'lire_config'); |
|
| 126 | + |
|
| 127 | + return $lire_config(substr($cfg, $p + 2), $def, $unserialize); |
|
| 128 | + } |
|
| 129 | + |
|
| 130 | + list($table, $casier, $sous_casier) = expliquer_config($cfg); |
|
| 131 | + |
|
| 132 | + if (!isset($GLOBALS[$table])) { |
|
| 133 | + return $def; |
|
| 134 | + } |
|
| 135 | + |
|
| 136 | + $r = $GLOBALS[$table]; |
|
| 137 | + |
|
| 138 | + // si on a demande #CONFIG{/meta,'',0} |
|
| 139 | + if (!$casier) { |
|
| 140 | + return $unserialize ? $r : serialize($r); |
|
| 141 | + } |
|
| 142 | + |
|
| 143 | + // casier principal : |
|
| 144 | + // le deserializer si demande |
|
| 145 | + // ou si on a besoin |
|
| 146 | + // d'un sous casier |
|
| 147 | + $r = isset($r[$casier]) ? $r[$casier] : null; |
|
| 148 | + if (($unserialize or count($sous_casier)) and $r and is_string($r)) { |
|
| 149 | + $r = (($t = @unserialize($r)) === false ? $r : $t); |
|
| 150 | + } |
|
| 151 | + |
|
| 152 | + // aller chercher le sous_casier |
|
| 153 | + while (!is_null($r) and $casier = array_shift($sous_casier)) { |
|
| 154 | + $r = isset($r[$casier]) ? $r[$casier] : null; |
|
| 155 | + } |
|
| 156 | + |
|
| 157 | + if (is_null($r)) { |
|
| 158 | + return $def; |
|
| 159 | + } |
|
| 160 | + |
|
| 161 | + return $r; |
|
| 162 | 162 | } |
| 163 | 163 | |
| 164 | 164 | /** |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | * @return mixed |
| 173 | 173 | */ |
| 174 | 174 | function lire_config_metapack_dist($cfg = '', $def = null, $unserialize = true) { |
| 175 | - return lire_config($cfg, $def, $unserialize); |
|
| 175 | + return lire_config($cfg, $def, $unserialize); |
|
| 176 | 176 | } |
| 177 | 177 | |
| 178 | 178 | |
@@ -184,98 +184,98 @@ discard block |
||
| 184 | 184 | * @return bool |
| 185 | 185 | */ |
| 186 | 186 | function ecrire_config($cfg, $store) { |
| 187 | - // Brancher sur methodes externes si besoin |
|
| 188 | - if ($cfg and $p = strpos($cfg, '::')) { |
|
| 189 | - $methode = substr($cfg, 0, $p); |
|
| 190 | - $ecrire_config = charger_fonction($methode, 'ecrire_config'); |
|
| 191 | - |
|
| 192 | - return $ecrire_config(substr($cfg, $p + 2), $store); |
|
| 193 | - } |
|
| 194 | - |
|
| 195 | - list($table, $casier, $sous_casier) = expliquer_config($cfg); |
|
| 196 | - // il faut au moins un casier pour ecrire |
|
| 197 | - if (!$casier) { |
|
| 198 | - return false; |
|
| 199 | - } |
|
| 200 | - |
|
| 201 | - // trouvons ou creons le pointeur sur le casier |
|
| 202 | - $st = isset($GLOBALS[$table][$casier]) ? $GLOBALS[$table][$casier] : null; |
|
| 203 | - if (!is_array($st) and ($sous_casier or is_array($store))) { |
|
| 204 | - $st = unserialize($st); |
|
| 205 | - if ($st === false) { |
|
| 206 | - // ne rien creer si c'est une demande d'effacement |
|
| 207 | - if (is_null($store)) { |
|
| 208 | - return false; |
|
| 209 | - } |
|
| 210 | - $st = array(); |
|
| 211 | - } |
|
| 212 | - } |
|
| 213 | - |
|
| 214 | - // si on a affaire a un sous caiser |
|
| 215 | - // il faut ecrire au bon endroit sans perdre les autres sous casier freres |
|
| 216 | - if ($c = $sous_casier) { |
|
| 217 | - $sc = &$st; |
|
| 218 | - $pointeurs = array(); |
|
| 219 | - while (count($c) and $cc = array_shift($c)) { |
|
| 220 | - // creer l'entree si elle n'existe pas |
|
| 221 | - if (!isset($sc[$cc])) { |
|
| 222 | - // si on essaye d'effacer une config qui n'existe pas |
|
| 223 | - // ne rien creer mais sortir |
|
| 224 | - if (is_null($store)) { |
|
| 225 | - return false; |
|
| 226 | - } |
|
| 227 | - $sc[$cc] = array(); |
|
| 228 | - } |
|
| 229 | - $pointeurs[$cc] = &$sc; |
|
| 230 | - $sc = &$sc[$cc]; |
|
| 231 | - } |
|
| 232 | - |
|
| 233 | - // si c'est une demande d'effacement |
|
| 234 | - if (is_null($store)) { |
|
| 235 | - $c = $sous_casier; |
|
| 236 | - $sous = array_pop($c); |
|
| 237 | - // effacer, et remonter pour effacer les parents vides |
|
| 238 | - do { |
|
| 239 | - unset($pointeurs[$sous][$sous]); |
|
| 240 | - } while ($sous = array_pop($c) and !count($pointeurs[$sous][$sous])); |
|
| 241 | - |
|
| 242 | - // si on a vide tous les sous casiers, |
|
| 243 | - // et que le casier est vide |
|
| 244 | - // vider aussi la meta |
|
| 245 | - if (!$sous and !count($st)) { |
|
| 246 | - $st = null; |
|
| 247 | - } |
|
| 248 | - } // dans tous les autres cas, on ecrase |
|
| 249 | - else { |
|
| 250 | - $sc = $store; |
|
| 251 | - } |
|
| 252 | - |
|
| 253 | - // Maintenant que $st est modifiee |
|
| 254 | - // reprenons la comme valeur a stocker dans le casier principal |
|
| 255 | - $store = $st; |
|
| 256 | - } |
|
| 257 | - |
|
| 258 | - if (is_null($store)) { |
|
| 259 | - if (is_null($st) and !$sous_casier) { |
|
| 260 | - return false; |
|
| 261 | - } // la config n'existait deja pas ! |
|
| 262 | - effacer_meta($casier, $table); |
|
| 263 | - supprimer_table_meta($table); // supprimons la table (si elle est bien vide) |
|
| 264 | - } // les meta ne peuvent etre que des chaines : il faut serializer le reste |
|
| 265 | - else { |
|
| 266 | - if (!isset($GLOBALS[$table])) { |
|
| 267 | - installer_table_meta($table); |
|
| 268 | - } |
|
| 269 | - // si ce n'est pas une chaine |
|
| 270 | - // il faut serializer |
|
| 271 | - if (!is_string($store)) { |
|
| 272 | - $store = serialize($store); |
|
| 273 | - } |
|
| 274 | - ecrire_meta($casier, $store, null, $table); |
|
| 275 | - } |
|
| 276 | - |
|
| 277 | - // verifier que lire_config($cfg)==$store ? |
|
| 278 | - return true; |
|
| 187 | + // Brancher sur methodes externes si besoin |
|
| 188 | + if ($cfg and $p = strpos($cfg, '::')) { |
|
| 189 | + $methode = substr($cfg, 0, $p); |
|
| 190 | + $ecrire_config = charger_fonction($methode, 'ecrire_config'); |
|
| 191 | + |
|
| 192 | + return $ecrire_config(substr($cfg, $p + 2), $store); |
|
| 193 | + } |
|
| 194 | + |
|
| 195 | + list($table, $casier, $sous_casier) = expliquer_config($cfg); |
|
| 196 | + // il faut au moins un casier pour ecrire |
|
| 197 | + if (!$casier) { |
|
| 198 | + return false; |
|
| 199 | + } |
|
| 200 | + |
|
| 201 | + // trouvons ou creons le pointeur sur le casier |
|
| 202 | + $st = isset($GLOBALS[$table][$casier]) ? $GLOBALS[$table][$casier] : null; |
|
| 203 | + if (!is_array($st) and ($sous_casier or is_array($store))) { |
|
| 204 | + $st = unserialize($st); |
|
| 205 | + if ($st === false) { |
|
| 206 | + // ne rien creer si c'est une demande d'effacement |
|
| 207 | + if (is_null($store)) { |
|
| 208 | + return false; |
|
| 209 | + } |
|
| 210 | + $st = array(); |
|
| 211 | + } |
|
| 212 | + } |
|
| 213 | + |
|
| 214 | + // si on a affaire a un sous caiser |
|
| 215 | + // il faut ecrire au bon endroit sans perdre les autres sous casier freres |
|
| 216 | + if ($c = $sous_casier) { |
|
| 217 | + $sc = &$st; |
|
| 218 | + $pointeurs = array(); |
|
| 219 | + while (count($c) and $cc = array_shift($c)) { |
|
| 220 | + // creer l'entree si elle n'existe pas |
|
| 221 | + if (!isset($sc[$cc])) { |
|
| 222 | + // si on essaye d'effacer une config qui n'existe pas |
|
| 223 | + // ne rien creer mais sortir |
|
| 224 | + if (is_null($store)) { |
|
| 225 | + return false; |
|
| 226 | + } |
|
| 227 | + $sc[$cc] = array(); |
|
| 228 | + } |
|
| 229 | + $pointeurs[$cc] = &$sc; |
|
| 230 | + $sc = &$sc[$cc]; |
|
| 231 | + } |
|
| 232 | + |
|
| 233 | + // si c'est une demande d'effacement |
|
| 234 | + if (is_null($store)) { |
|
| 235 | + $c = $sous_casier; |
|
| 236 | + $sous = array_pop($c); |
|
| 237 | + // effacer, et remonter pour effacer les parents vides |
|
| 238 | + do { |
|
| 239 | + unset($pointeurs[$sous][$sous]); |
|
| 240 | + } while ($sous = array_pop($c) and !count($pointeurs[$sous][$sous])); |
|
| 241 | + |
|
| 242 | + // si on a vide tous les sous casiers, |
|
| 243 | + // et que le casier est vide |
|
| 244 | + // vider aussi la meta |
|
| 245 | + if (!$sous and !count($st)) { |
|
| 246 | + $st = null; |
|
| 247 | + } |
|
| 248 | + } // dans tous les autres cas, on ecrase |
|
| 249 | + else { |
|
| 250 | + $sc = $store; |
|
| 251 | + } |
|
| 252 | + |
|
| 253 | + // Maintenant que $st est modifiee |
|
| 254 | + // reprenons la comme valeur a stocker dans le casier principal |
|
| 255 | + $store = $st; |
|
| 256 | + } |
|
| 257 | + |
|
| 258 | + if (is_null($store)) { |
|
| 259 | + if (is_null($st) and !$sous_casier) { |
|
| 260 | + return false; |
|
| 261 | + } // la config n'existait deja pas ! |
|
| 262 | + effacer_meta($casier, $table); |
|
| 263 | + supprimer_table_meta($table); // supprimons la table (si elle est bien vide) |
|
| 264 | + } // les meta ne peuvent etre que des chaines : il faut serializer le reste |
|
| 265 | + else { |
|
| 266 | + if (!isset($GLOBALS[$table])) { |
|
| 267 | + installer_table_meta($table); |
|
| 268 | + } |
|
| 269 | + // si ce n'est pas une chaine |
|
| 270 | + // il faut serializer |
|
| 271 | + if (!is_string($store)) { |
|
| 272 | + $store = serialize($store); |
|
| 273 | + } |
|
| 274 | + ecrire_meta($casier, $store, null, $table); |
|
| 275 | + } |
|
| 276 | + |
|
| 277 | + // verifier que lire_config($cfg)==$store ? |
|
| 278 | + return true; |
|
| 279 | 279 | } |
| 280 | 280 | |
| 281 | 281 | |
@@ -289,14 +289,14 @@ discard block |
||
| 289 | 289 | * @return bool |
| 290 | 290 | */ |
| 291 | 291 | function ecrire_config_metapack_dist($cfg, $store) { |
| 292 | - // cas particulier en metapack:: |
|
| 293 | - // si on ecrit une chaine deja serializee, il faut la reserializer pour la rendre |
|
| 294 | - // intacte en sortie ... |
|
| 295 | - if (is_string($store) and strpos($store, ':') and unserialize($store)) { |
|
| 296 | - $store = serialize($store); |
|
| 297 | - } |
|
| 298 | - |
|
| 299 | - return ecrire_config($cfg, $store); |
|
| 292 | + // cas particulier en metapack:: |
|
| 293 | + // si on ecrit une chaine deja serializee, il faut la reserializer pour la rendre |
|
| 294 | + // intacte en sortie ... |
|
| 295 | + if (is_string($store) and strpos($store, ':') and unserialize($store)) { |
|
| 296 | + $store = serialize($store); |
|
| 297 | + } |
|
| 298 | + |
|
| 299 | + return ecrire_config($cfg, $store); |
|
| 300 | 300 | } |
| 301 | 301 | |
| 302 | 302 | /** |
@@ -306,9 +306,9 @@ discard block |
||
| 306 | 306 | * @return bool |
| 307 | 307 | */ |
| 308 | 308 | function effacer_config($cfg) { |
| 309 | - ecrire_config($cfg, null); |
|
| 309 | + ecrire_config($cfg, null); |
|
| 310 | 310 | |
| 311 | - return true; |
|
| 311 | + return true; |
|
| 312 | 312 | } |
| 313 | 313 | |
| 314 | 314 | /** |
@@ -325,71 +325,71 @@ discard block |
||
| 325 | 325 | * @return array |
| 326 | 326 | */ |
| 327 | 327 | function lister_configurer($exclure = array()) { |
| 328 | - return array(); |
|
| 329 | - |
|
| 330 | - // lister les pages de config deja dans les menus |
|
| 331 | - $deja = array(); |
|
| 332 | - foreach ($exclure as $id => $b) { |
|
| 333 | - $url = ($b['url'] ? $b['url'] : $id); |
|
| 334 | - if (!$b['url'] or !isset($exclure[$url])) { |
|
| 335 | - if (strncmp($url, 'configurer_', 11) == 0) { |
|
| 336 | - $deja[$url] = $b; |
|
| 337 | - } elseif ($b['url'] == 'configurer' and preg_match(',cfg=([a-z0-9_]+),i', $b['args'], $match)) { |
|
| 338 | - $deja["configurer_" . $match[1]] = $b; |
|
| 339 | - } |
|
| 340 | - } |
|
| 341 | - |
|
| 342 | - } |
|
| 343 | - $exclure = $exclure + $deja; |
|
| 344 | - |
|
| 345 | - $icone_defaut = "images/configuration-16.png"; |
|
| 346 | - $liste = array(); |
|
| 347 | - $skels = array(); |
|
| 348 | - $forms = array(); |
|
| 349 | - |
|
| 350 | - // trouver toutes les pages configurer_xxx de l'espace prive |
|
| 351 | - // et construire un tableau des entrees qui ne sont pas dans $deja |
|
| 352 | - $pages = find_all_in_path("prive/squelettes/contenu/", "configurer_.*[.]" . _EXTENSION_SQUELETTES . '$'); |
|
| 353 | - |
|
| 354 | - foreach ($pages as $page) { |
|
| 355 | - $configurer = basename($page, "." . _EXTENSION_SQUELETTES); |
|
| 356 | - if (!isset($exclure[$configurer])) { |
|
| 357 | - $liste[$configurer] = array( |
|
| 358 | - 'parent' => 'bando_configuration', |
|
| 359 | - 'url' => $configurer, |
|
| 360 | - 'titre' => _T("configurer:{$configurer}_titre"), |
|
| 361 | - 'icone' => find_in_theme($i = "images/{$configurer}-16.png") ? $i : $icone_defaut, |
|
| 362 | - ); |
|
| 363 | - } |
|
| 364 | - $skels[$configurer] = $page; |
|
| 365 | - } |
|
| 366 | - |
|
| 367 | - // analyser la liste des $skels pour voir les #FORMULAIRE_CONFIGURER_ inclus |
|
| 368 | - foreach ($skels as $file) { |
|
| 369 | - $forms = array_merge($forms, lister_formulaires_configurer($file)); |
|
| 370 | - } |
|
| 371 | - $forms = array_flip($forms); |
|
| 372 | - |
|
| 373 | - // trouver tous les formulaires/configurer_ |
|
| 374 | - // et construire un tableau des entrees |
|
| 375 | - $pages = find_all_in_path("formulaires/", "configurer_.*[.]" . _EXTENSION_SQUELETTES . '$'); |
|
| 376 | - foreach ($pages as $page) { |
|
| 377 | - $configurer = basename($page, "." . _EXTENSION_SQUELETTES); |
|
| 378 | - if (!isset($forms[$configurer]) |
|
| 379 | - and !isset($liste[$configurer]) |
|
| 380 | - and !isset($exclure[$configurer]) |
|
| 381 | - ) { |
|
| 382 | - $liste[$configurer] = array( |
|
| 383 | - 'parent' => 'bando_configuration', |
|
| 384 | - 'url' => 'configurer', |
|
| 385 | - 'args' => 'cfg=' . substr($configurer, 11), |
|
| 386 | - 'titre' => _T("configurer:{$configurer}_titre"), |
|
| 387 | - 'icone' => find_in_theme($i = "images/{$configurer}-16.png") ? $i : $icone_defaut, |
|
| 388 | - ); |
|
| 389 | - } |
|
| 390 | - } |
|
| 391 | - |
|
| 392 | - return $liste; |
|
| 328 | + return array(); |
|
| 329 | + |
|
| 330 | + // lister les pages de config deja dans les menus |
|
| 331 | + $deja = array(); |
|
| 332 | + foreach ($exclure as $id => $b) { |
|
| 333 | + $url = ($b['url'] ? $b['url'] : $id); |
|
| 334 | + if (!$b['url'] or !isset($exclure[$url])) { |
|
| 335 | + if (strncmp($url, 'configurer_', 11) == 0) { |
|
| 336 | + $deja[$url] = $b; |
|
| 337 | + } elseif ($b['url'] == 'configurer' and preg_match(',cfg=([a-z0-9_]+),i', $b['args'], $match)) { |
|
| 338 | + $deja["configurer_" . $match[1]] = $b; |
|
| 339 | + } |
|
| 340 | + } |
|
| 341 | + |
|
| 342 | + } |
|
| 343 | + $exclure = $exclure + $deja; |
|
| 344 | + |
|
| 345 | + $icone_defaut = "images/configuration-16.png"; |
|
| 346 | + $liste = array(); |
|
| 347 | + $skels = array(); |
|
| 348 | + $forms = array(); |
|
| 349 | + |
|
| 350 | + // trouver toutes les pages configurer_xxx de l'espace prive |
|
| 351 | + // et construire un tableau des entrees qui ne sont pas dans $deja |
|
| 352 | + $pages = find_all_in_path("prive/squelettes/contenu/", "configurer_.*[.]" . _EXTENSION_SQUELETTES . '$'); |
|
| 353 | + |
|
| 354 | + foreach ($pages as $page) { |
|
| 355 | + $configurer = basename($page, "." . _EXTENSION_SQUELETTES); |
|
| 356 | + if (!isset($exclure[$configurer])) { |
|
| 357 | + $liste[$configurer] = array( |
|
| 358 | + 'parent' => 'bando_configuration', |
|
| 359 | + 'url' => $configurer, |
|
| 360 | + 'titre' => _T("configurer:{$configurer}_titre"), |
|
| 361 | + 'icone' => find_in_theme($i = "images/{$configurer}-16.png") ? $i : $icone_defaut, |
|
| 362 | + ); |
|
| 363 | + } |
|
| 364 | + $skels[$configurer] = $page; |
|
| 365 | + } |
|
| 366 | + |
|
| 367 | + // analyser la liste des $skels pour voir les #FORMULAIRE_CONFIGURER_ inclus |
|
| 368 | + foreach ($skels as $file) { |
|
| 369 | + $forms = array_merge($forms, lister_formulaires_configurer($file)); |
|
| 370 | + } |
|
| 371 | + $forms = array_flip($forms); |
|
| 372 | + |
|
| 373 | + // trouver tous les formulaires/configurer_ |
|
| 374 | + // et construire un tableau des entrees |
|
| 375 | + $pages = find_all_in_path("formulaires/", "configurer_.*[.]" . _EXTENSION_SQUELETTES . '$'); |
|
| 376 | + foreach ($pages as $page) { |
|
| 377 | + $configurer = basename($page, "." . _EXTENSION_SQUELETTES); |
|
| 378 | + if (!isset($forms[$configurer]) |
|
| 379 | + and !isset($liste[$configurer]) |
|
| 380 | + and !isset($exclure[$configurer]) |
|
| 381 | + ) { |
|
| 382 | + $liste[$configurer] = array( |
|
| 383 | + 'parent' => 'bando_configuration', |
|
| 384 | + 'url' => 'configurer', |
|
| 385 | + 'args' => 'cfg=' . substr($configurer, 11), |
|
| 386 | + 'titre' => _T("configurer:{$configurer}_titre"), |
|
| 387 | + 'icone' => find_in_theme($i = "images/{$configurer}-16.png") ? $i : $icone_defaut, |
|
| 388 | + ); |
|
| 389 | + } |
|
| 390 | + } |
|
| 391 | + |
|
| 392 | + return $liste; |
|
| 393 | 393 | } |
| 394 | 394 | |
| 395 | 395 | |
@@ -403,35 +403,35 @@ discard block |
||
| 403 | 403 | * Liste des formulaires trouvés |
| 404 | 404 | **/ |
| 405 | 405 | function lister_formulaires_configurer($file) { |
| 406 | - $forms = array(); |
|
| 407 | - |
|
| 408 | - lire_fichier($file, $skel); |
|
| 409 | - if (preg_match_all(",#FORMULAIRE_(CONFIGURER_[A-Z0-9_]*),", $skel, $matches, PREG_SET_ORDER)) { |
|
| 410 | - $matches = array_map('end', $matches); |
|
| 411 | - $matches = array_map('strtolower', $matches); |
|
| 412 | - $forms = array_merge($forms, $matches); |
|
| 413 | - } |
|
| 414 | - |
|
| 415 | - // evaluer le fond en lui passant un exec coherent pour que les pipelines le reconnaissent |
|
| 416 | - // et reperer les formulaires CVT configurer_xx insereres par les plugins via pipeline |
|
| 417 | - $config = basename(substr($file, 0, -strlen("." . _EXTENSION_SQUELETTES))); |
|
| 418 | - spip_log('Calcul de ' . "prive/squelettes/contenu/$config"); |
|
| 419 | - $fond = recuperer_fond("prive/squelettes/contenu/$config", array("exec" => $config)); |
|
| 420 | - |
|
| 421 | - // passer dans le pipeline affiche_milieu pour que les plugins puissent ajouter leur formulaires... |
|
| 422 | - // et donc que l'on puisse les referencer aussi ! |
|
| 423 | - $fond = pipeline('affiche_milieu', array('args' => array("exec" => $config), 'data' => $fond)); |
|
| 424 | - |
|
| 425 | - // recuperer les noms des formulaires presents. |
|
| 426 | - if (is_array($inputs = extraire_balises($fond, "input"))) { |
|
| 427 | - foreach ($inputs as $i) { |
|
| 428 | - if (extraire_attribut($i, 'name') == 'formulaire_action') { |
|
| 429 | - $forms[] = ($c = extraire_attribut($i, 'value')); |
|
| 430 | - } |
|
| 431 | - } |
|
| 432 | - } |
|
| 433 | - |
|
| 434 | - return $forms; |
|
| 406 | + $forms = array(); |
|
| 407 | + |
|
| 408 | + lire_fichier($file, $skel); |
|
| 409 | + if (preg_match_all(",#FORMULAIRE_(CONFIGURER_[A-Z0-9_]*),", $skel, $matches, PREG_SET_ORDER)) { |
|
| 410 | + $matches = array_map('end', $matches); |
|
| 411 | + $matches = array_map('strtolower', $matches); |
|
| 412 | + $forms = array_merge($forms, $matches); |
|
| 413 | + } |
|
| 414 | + |
|
| 415 | + // evaluer le fond en lui passant un exec coherent pour que les pipelines le reconnaissent |
|
| 416 | + // et reperer les formulaires CVT configurer_xx insereres par les plugins via pipeline |
|
| 417 | + $config = basename(substr($file, 0, -strlen("." . _EXTENSION_SQUELETTES))); |
|
| 418 | + spip_log('Calcul de ' . "prive/squelettes/contenu/$config"); |
|
| 419 | + $fond = recuperer_fond("prive/squelettes/contenu/$config", array("exec" => $config)); |
|
| 420 | + |
|
| 421 | + // passer dans le pipeline affiche_milieu pour que les plugins puissent ajouter leur formulaires... |
|
| 422 | + // et donc que l'on puisse les referencer aussi ! |
|
| 423 | + $fond = pipeline('affiche_milieu', array('args' => array("exec" => $config), 'data' => $fond)); |
|
| 424 | + |
|
| 425 | + // recuperer les noms des formulaires presents. |
|
| 426 | + if (is_array($inputs = extraire_balises($fond, "input"))) { |
|
| 427 | + foreach ($inputs as $i) { |
|
| 428 | + if (extraire_attribut($i, 'name') == 'formulaire_action') { |
|
| 429 | + $forms[] = ($c = extraire_attribut($i, 'value')); |
|
| 430 | + } |
|
| 431 | + } |
|
| 432 | + } |
|
| 433 | + |
|
| 434 | + return $forms; |
|
| 435 | 435 | } |
| 436 | 436 | |
| 437 | 437 | |
@@ -449,58 +449,58 @@ discard block |
||
| 449 | 449 | * Couples nom de la `meta` => valeur par défaut |
| 450 | 450 | */ |
| 451 | 451 | function liste_metas() { |
| 452 | - return pipeline('configurer_liste_metas', array( |
|
| 453 | - 'nom_site' => _T('info_mon_site_spip'), |
|
| 454 | - 'slogan_site' => '', |
|
| 455 | - 'adresse_site' => preg_replace(",/$,", "", url_de_base()), |
|
| 456 | - 'descriptif_site' => '', |
|
| 457 | - 'activer_logos' => 'oui', |
|
| 458 | - 'activer_logos_survol' => 'non', |
|
| 459 | - 'articles_surtitre' => 'non', |
|
| 460 | - 'articles_soustitre' => 'non', |
|
| 461 | - 'articles_descriptif' => 'non', |
|
| 462 | - 'articles_chapeau' => 'non', |
|
| 463 | - 'articles_texte' => 'oui', |
|
| 464 | - 'articles_ps' => 'non', |
|
| 465 | - 'articles_redac' => 'non', |
|
| 466 | - 'post_dates' => 'non', |
|
| 467 | - 'articles_urlref' => 'non', |
|
| 468 | - 'articles_redirection' => 'non', |
|
| 469 | - 'creer_preview' => 'non', |
|
| 470 | - 'taille_preview' => 150, |
|
| 471 | - 'articles_modif' => 'non', |
|
| 472 | - |
|
| 473 | - 'rubriques_descriptif' => 'non', |
|
| 474 | - 'rubriques_texte' => 'oui', |
|
| 475 | - |
|
| 476 | - 'accepter_inscriptions' => 'non', |
|
| 477 | - 'accepter_visiteurs' => 'non', |
|
| 478 | - 'prevenir_auteurs' => 'non', |
|
| 479 | - 'suivi_edito' => 'non', |
|
| 480 | - 'adresse_suivi' => '', |
|
| 481 | - 'adresse_suivi_inscription' => '', |
|
| 482 | - 'adresse_neuf' => '', |
|
| 483 | - 'jours_neuf' => '', |
|
| 484 | - 'quoi_de_neuf' => 'non', |
|
| 485 | - 'preview' => ',0minirezo,1comite,', |
|
| 486 | - |
|
| 487 | - 'syndication_integrale' => 'oui', |
|
| 488 | - 'charset' => _DEFAULT_CHARSET, |
|
| 489 | - 'dir_img' => substr(_DIR_IMG, strlen(_DIR_RACINE)), |
|
| 490 | - |
|
| 491 | - 'multi_rubriques' => 'non', |
|
| 492 | - 'multi_secteurs' => 'non', |
|
| 493 | - 'gerer_trad' => 'non', |
|
| 494 | - 'langues_multilingue' => '', |
|
| 495 | - |
|
| 496 | - 'version_html_max' => 'html4', |
|
| 497 | - |
|
| 498 | - 'type_urls' => 'page', |
|
| 499 | - |
|
| 500 | - 'email_envoi' => '', |
|
| 501 | - 'email_webmaster' => '', |
|
| 502 | - 'auto_compress_http' => 'non', |
|
| 503 | - )); |
|
| 452 | + return pipeline('configurer_liste_metas', array( |
|
| 453 | + 'nom_site' => _T('info_mon_site_spip'), |
|
| 454 | + 'slogan_site' => '', |
|
| 455 | + 'adresse_site' => preg_replace(",/$,", "", url_de_base()), |
|
| 456 | + 'descriptif_site' => '', |
|
| 457 | + 'activer_logos' => 'oui', |
|
| 458 | + 'activer_logos_survol' => 'non', |
|
| 459 | + 'articles_surtitre' => 'non', |
|
| 460 | + 'articles_soustitre' => 'non', |
|
| 461 | + 'articles_descriptif' => 'non', |
|
| 462 | + 'articles_chapeau' => 'non', |
|
| 463 | + 'articles_texte' => 'oui', |
|
| 464 | + 'articles_ps' => 'non', |
|
| 465 | + 'articles_redac' => 'non', |
|
| 466 | + 'post_dates' => 'non', |
|
| 467 | + 'articles_urlref' => 'non', |
|
| 468 | + 'articles_redirection' => 'non', |
|
| 469 | + 'creer_preview' => 'non', |
|
| 470 | + 'taille_preview' => 150, |
|
| 471 | + 'articles_modif' => 'non', |
|
| 472 | + |
|
| 473 | + 'rubriques_descriptif' => 'non', |
|
| 474 | + 'rubriques_texte' => 'oui', |
|
| 475 | + |
|
| 476 | + 'accepter_inscriptions' => 'non', |
|
| 477 | + 'accepter_visiteurs' => 'non', |
|
| 478 | + 'prevenir_auteurs' => 'non', |
|
| 479 | + 'suivi_edito' => 'non', |
|
| 480 | + 'adresse_suivi' => '', |
|
| 481 | + 'adresse_suivi_inscription' => '', |
|
| 482 | + 'adresse_neuf' => '', |
|
| 483 | + 'jours_neuf' => '', |
|
| 484 | + 'quoi_de_neuf' => 'non', |
|
| 485 | + 'preview' => ',0minirezo,1comite,', |
|
| 486 | + |
|
| 487 | + 'syndication_integrale' => 'oui', |
|
| 488 | + 'charset' => _DEFAULT_CHARSET, |
|
| 489 | + 'dir_img' => substr(_DIR_IMG, strlen(_DIR_RACINE)), |
|
| 490 | + |
|
| 491 | + 'multi_rubriques' => 'non', |
|
| 492 | + 'multi_secteurs' => 'non', |
|
| 493 | + 'gerer_trad' => 'non', |
|
| 494 | + 'langues_multilingue' => '', |
|
| 495 | + |
|
| 496 | + 'version_html_max' => 'html4', |
|
| 497 | + |
|
| 498 | + 'type_urls' => 'page', |
|
| 499 | + |
|
| 500 | + 'email_envoi' => '', |
|
| 501 | + 'email_webmaster' => '', |
|
| 502 | + 'auto_compress_http' => 'non', |
|
| 503 | + )); |
|
| 504 | 504 | } |
| 505 | 505 | |
| 506 | 506 | /** |
@@ -511,43 +511,43 @@ discard block |
||
| 511 | 511 | * @return void |
| 512 | 512 | */ |
| 513 | 513 | function actualise_metas($liste_meta) { |
| 514 | - $meta_serveur = |
|
| 515 | - array( |
|
| 516 | - 'version_installee', |
|
| 517 | - 'adresse_site', |
|
| 518 | - 'alea_ephemere_ancien', |
|
| 519 | - 'alea_ephemere', |
|
| 520 | - 'alea_ephemere_date', |
|
| 521 | - 'langue_site', |
|
| 522 | - 'langues_proposees', |
|
| 523 | - 'date_calcul_rubriques', |
|
| 524 | - 'derniere_modif', |
|
| 525 | - 'optimiser_table', |
|
| 526 | - 'drapeau_edition', |
|
| 527 | - 'creer_preview', |
|
| 528 | - 'taille_preview', |
|
| 529 | - 'creer_htpasswd', |
|
| 530 | - 'creer_htaccess', |
|
| 531 | - 'gd_formats_read', |
|
| 532 | - 'gd_formats', |
|
| 533 | - 'netpbm_formats', |
|
| 534 | - 'formats_graphiques', |
|
| 535 | - 'image_process', |
|
| 536 | - 'plugin_header', |
|
| 537 | - 'plugin' |
|
| 538 | - ); |
|
| 539 | - // verifier le impt=non |
|
| 540 | - sql_updateq('spip_meta', array('impt' => 'non'), sql_in('nom', $meta_serveur)); |
|
| 541 | - |
|
| 542 | - foreach ($liste_meta as $nom => $valeur) { |
|
| 543 | - if (empty($GLOBALS['meta'][$nom])) { |
|
| 544 | - ecrire_meta($nom, $valeur); |
|
| 545 | - } |
|
| 546 | - } |
|
| 547 | - |
|
| 548 | - include_spip('inc/rubriques'); |
|
| 549 | - $langues = calculer_langues_utilisees(); |
|
| 550 | - ecrire_meta('langues_utilisees', $langues); |
|
| 514 | + $meta_serveur = |
|
| 515 | + array( |
|
| 516 | + 'version_installee', |
|
| 517 | + 'adresse_site', |
|
| 518 | + 'alea_ephemere_ancien', |
|
| 519 | + 'alea_ephemere', |
|
| 520 | + 'alea_ephemere_date', |
|
| 521 | + 'langue_site', |
|
| 522 | + 'langues_proposees', |
|
| 523 | + 'date_calcul_rubriques', |
|
| 524 | + 'derniere_modif', |
|
| 525 | + 'optimiser_table', |
|
| 526 | + 'drapeau_edition', |
|
| 527 | + 'creer_preview', |
|
| 528 | + 'taille_preview', |
|
| 529 | + 'creer_htpasswd', |
|
| 530 | + 'creer_htaccess', |
|
| 531 | + 'gd_formats_read', |
|
| 532 | + 'gd_formats', |
|
| 533 | + 'netpbm_formats', |
|
| 534 | + 'formats_graphiques', |
|
| 535 | + 'image_process', |
|
| 536 | + 'plugin_header', |
|
| 537 | + 'plugin' |
|
| 538 | + ); |
|
| 539 | + // verifier le impt=non |
|
| 540 | + sql_updateq('spip_meta', array('impt' => 'non'), sql_in('nom', $meta_serveur)); |
|
| 541 | + |
|
| 542 | + foreach ($liste_meta as $nom => $valeur) { |
|
| 543 | + if (empty($GLOBALS['meta'][$nom])) { |
|
| 544 | + ecrire_meta($nom, $valeur); |
|
| 545 | + } |
|
| 546 | + } |
|
| 547 | + |
|
| 548 | + include_spip('inc/rubriques'); |
|
| 549 | + $langues = calculer_langues_utilisees(); |
|
| 550 | + ecrire_meta('langues_utilisees', $langues); |
|
| 551 | 551 | } |
| 552 | 552 | |
| 553 | 553 | |
@@ -569,18 +569,18 @@ discard block |
||
| 569 | 569 | */ |
| 570 | 570 | function appliquer_modifs_config($purger_skel = false) { |
| 571 | 571 | |
| 572 | - foreach (liste_metas() as $i => $v) { |
|
| 573 | - if (($x = _request($i)) !== null) { |
|
| 574 | - ecrire_meta($i, $x); |
|
| 575 | - } elseif (!isset($GLOBALS['meta'][$i])) { |
|
| 576 | - ecrire_meta($i, $v); |
|
| 577 | - } |
|
| 578 | - } |
|
| 579 | - |
|
| 580 | - if ($purger_skel) { |
|
| 581 | - include_spip('inc/invalideur'); |
|
| 582 | - purger_repertoire(_DIR_SKELS); |
|
| 583 | - } |
|
| 572 | + foreach (liste_metas() as $i => $v) { |
|
| 573 | + if (($x = _request($i)) !== null) { |
|
| 574 | + ecrire_meta($i, $x); |
|
| 575 | + } elseif (!isset($GLOBALS['meta'][$i])) { |
|
| 576 | + ecrire_meta($i, $v); |
|
| 577 | + } |
|
| 578 | + } |
|
| 579 | + |
|
| 580 | + if ($purger_skel) { |
|
| 581 | + include_spip('inc/invalideur'); |
|
| 582 | + purger_repertoire(_DIR_SKELS); |
|
| 583 | + } |
|
| 584 | 584 | } |
| 585 | 585 | |
| 586 | 586 | /** |
@@ -591,21 +591,21 @@ discard block |
||
| 591 | 591 | * @return string |
| 592 | 592 | */ |
| 593 | 593 | function appliquer_adresse_site($adresse_site) { |
| 594 | - if ($adresse_site !== null) { |
|
| 595 | - if (!strlen($adresse_site)) { |
|
| 596 | - $GLOBALS['profondeur_url'] = _DIR_RESTREINT ? 0 : 1; |
|
| 597 | - $adresse_site = url_de_base(); |
|
| 598 | - } |
|
| 599 | - $adresse_site = preg_replace(",/?\s*$,", "", $adresse_site); |
|
| 594 | + if ($adresse_site !== null) { |
|
| 595 | + if (!strlen($adresse_site)) { |
|
| 596 | + $GLOBALS['profondeur_url'] = _DIR_RESTREINT ? 0 : 1; |
|
| 597 | + $adresse_site = url_de_base(); |
|
| 598 | + } |
|
| 599 | + $adresse_site = preg_replace(",/?\s*$,", "", $adresse_site); |
|
| 600 | 600 | |
| 601 | - if (!tester_url_absolue($adresse_site)) { |
|
| 602 | - $adresse_site = "http://$adresse_site"; |
|
| 603 | - } |
|
| 601 | + if (!tester_url_absolue($adresse_site)) { |
|
| 602 | + $adresse_site = "http://$adresse_site"; |
|
| 603 | + } |
|
| 604 | 604 | |
| 605 | - $adresse_site = entites_html($adresse_site); |
|
| 605 | + $adresse_site = entites_html($adresse_site); |
|
| 606 | 606 | |
| 607 | - ecrire_meta('adresse_site', $adresse_site); |
|
| 608 | - } |
|
| 607 | + ecrire_meta('adresse_site', $adresse_site); |
|
| 608 | + } |
|
| 609 | 609 | |
| 610 | - return $adresse_site; |
|
| 610 | + return $adresse_site; |
|
| 611 | 611 | } |