Completed
Push — master ( 81a660...8ce9c8 )
by cam
01:32
created
ecrire/install/etape_2.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 	$GLOBALS['connexions'][$server_db] = $link;
49 49
 
50 50
 	$GLOBALS['connexions'][$server_db][$GLOBALS['spip_sql_version']]
51
-		= $GLOBALS['spip_' . $server_db . '_functions_' . $GLOBALS['spip_sql_version']];
51
+		= $GLOBALS['spip_'.$server_db.'_functions_'.$GLOBALS['spip_sql_version']];
52 52
 
53 53
 	$minipage = new Spip\Afficher\Minipage\Installation();
54 54
 	echo $minipage->installDebutPage();
@@ -68,18 +68,18 @@  discard block
 block discarded – undo
68 68
 	//echo "\n-->\n";
69 69
 
70 70
 	if (($db_connect == '0') && $link) {
71
-		echo "<div class='success'><b>" . _T('info_connexion_ok') . '</b></div>';
71
+		echo "<div class='success'><b>"._T('info_connexion_ok').'</b></div>';
72 72
 		echo info_progression_etape(2, 'etape_', 'install/');
73 73
 
74
-		echo info_etape(_T('menu_aide_installation_choix_base') . aider('install2', true));
74
+		echo info_etape(_T('menu_aide_installation_choix_base').aider('install2', true));
75 75
 
76 76
 		echo "\n", '<!-- ', sql_version($server_db), ' -->';
77 77
 		[$checked, $res] = install_etape_2_bases($login_db, $server_db);
78 78
 
79 79
 		$hidden = (defined('_SPIP_CHMOD')
80 80
 				? ''
81
-				: ("\n<input type='hidden' name='chmod' value='" . spip_htmlspecialchars($chmod) . "' />"))
82
-			. predef_ou_cache($adresse_db . ($port ? ':' . $port : ''), $login_db, $pass_db, $server_db);
81
+				: ("\n<input type='hidden' name='chmod' value='".spip_htmlspecialchars($chmod)."' />"))
82
+			. predef_ou_cache($adresse_db.($port ? ':'.$port : ''), $login_db, $pass_db, $server_db);
83 83
 
84 84
 		echo install_etape_2_form($hidden, $checked, $res, 3);
85 85
 	} else {
@@ -87,8 +87,8 @@  discard block
 block discarded – undo
87 87
 
88 88
 		echo "<div class='error'>";
89 89
 		echo info_etape(_T('info_connexion_base'));
90
-		echo '<h3>' . _T('avis_connexion_echec_1') . '</h3>';
91
-		echo '<p>' . _T('avis_connexion_echec_2') . '</p>';
90
+		echo '<h3>'._T('avis_connexion_echec_1').'</h3>';
91
+		echo '<p>'._T('avis_connexion_echec_2').'</p>';
92 92
 
93 93
 		echo "<p style='font-size: small;'>",
94 94
 		_T('avis_connexion_echec_3'),
@@ -120,8 +120,8 @@  discard block
 block discarded – undo
120 120
 			. ' '
121 121
 		];
122 122
 	}
123
-	$res = '<b>' . _T('avis_lecture_noms_bases_1') . '</b>
124
-		' . _T('avis_lecture_noms_bases_2') . '<p>';
123
+	$res = '<b>'._T('avis_lecture_noms_bases_1').'</b>
124
+		' . _T('avis_lecture_noms_bases_2').'<p>';
125 125
 
126 126
 	$checked = false;
127 127
 	if ($login_db) {
@@ -138,10 +138,10 @@  discard block
 block discarded – undo
138 138
 		if ($ok) {
139 139
 			$res .= _T('avis_lecture_noms_bases_3')
140 140
 				. '<ul>'
141
-				. '<li><input name="choix_db" value="' . $test_base . "\" type='radio' id='stand' checked='checked' />"
142
-				. "<label for='stand'>" . $test_base . "</label></li>\n"
141
+				. '<li><input name="choix_db" value="'.$test_base."\" type='radio' id='stand' checked='checked' />"
142
+				. "<label for='stand'>".$test_base."</label></li>\n"
143 143
 				. '</ul>'
144
-				. '<p>' . _T('info_ou') . ' ';
144
+				. '<p>'._T('info_ou').' ';
145 145
 			$checked = true;
146 146
 		}
147 147
 	}
@@ -154,19 +154,19 @@  discard block
 block discarded – undo
154 154
 		"\n<input type='hidden' name='etape' value='$etape' />"
155 155
 		. $hidden
156 156
 		. (defined('_INSTALL_NAME_DB')
157
-			? '<h3>' . _T('install_nom_base_hebergeur') . ' <tt>' . _INSTALL_NAME_DB . '</tt>' . '</h3>'
158
-			: "\n<fieldset><legend>" . _T('texte_choix_base_1') . "</legend>\n"
157
+			? '<h3>'._T('install_nom_base_hebergeur').' <tt>'._INSTALL_NAME_DB.'</tt>'.'</h3>'
158
+			: "\n<fieldset><legend>"._T('texte_choix_base_1')."</legend>\n"
159 159
 			. $res
160 160
 			. "\n<input name=\"choix_db\" value=\"new_spip\" type='radio' id='nou'"
161 161
 			. ($checked ? '' : " checked='checked'")
162
-			. " />\n<label for='nou'>" . _T('info_creer_base') . "</label></p>\n<p>"
162
+			. " />\n<label for='nou'>"._T('info_creer_base')."</label></p>\n<p>"
163 163
 			. "\n<input type='text' name='table_new' class='text' value=\"spip\" size='20' /></p></fieldset>\n"
164 164
 		)
165 165
 
166 166
 		. ((defined('_INSTALL_TABLE_PREFIX') || $GLOBALS['table_prefix'] != 'spip')
167
-			? '<h3>' . _T('install_table_prefix_hebergeur') . '  <tt>' . $GLOBALS['table_prefix'] . '</tt>' . '</h3>'
168
-			: '<fieldset><legend>' . _T('texte_choix_table_prefix') . "</legend>\n"
169
-			. "<p><label for='table_prefix'>" . _T('info_table_prefix') . '</label></p><p>'
167
+			? '<h3>'._T('install_table_prefix_hebergeur').'  <tt>'.$GLOBALS['table_prefix'].'</tt>'.'</h3>'
168
+			: '<fieldset><legend>'._T('texte_choix_table_prefix')."</legend>\n"
169
+			. "<p><label for='table_prefix'>"._T('info_table_prefix').'</label></p><p>'
170 170
 			. "\n<input type='text' id='tprefix' name='tprefix' class='text' value='"
171 171
 			. 'spip' # valeur par defaut
172 172
 			. "' size='20' /></p></fieldset>"
Please login to merge, or discard this patch.
ecrire/install/etape_ldap5.php 1 patch
Spacing   +6 added lines, -7 removed lines patch added patch discarded remove patch
@@ -51,29 +51,28 @@  discard block
 block discarded – undo
51 51
 	$conn = "\$GLOBALS['ldap_base'] = '$base_ldap';\n"
52 52
 		. "\$GLOBALS['ldap_link'] = @ldap_connect('$adresse_ldap','$port_ldap');\n"
53 53
 		. "@ldap_set_option(\$GLOBALS['ldap_link'],LDAP_OPT_PROTOCOL_VERSION,'$protocole_ldap');\n"
54
-		. (($tls_ldap != 'oui') ? '' :
55
-			"@ldap_start_tls(\$GLOBALS['ldap_link']);\n")
54
+		. (($tls_ldap != 'oui') ? '' : "@ldap_start_tls(\$GLOBALS['ldap_link']);\n")
56 55
 		. "@ldap_bind(\$GLOBALS['ldap_link'],'$login_ldap','$pass_ldap');\n";
57 56
 
58 57
 	$champs = is_array($GLOBALS['ldap_attributes']) ? $GLOBALS['ldap_attributes'] : [];
59 58
 	$res = '';
60 59
 	foreach (array_keys($champs) as $champ) {
61
-		$nom = 'ldap_' . $champ;
60
+		$nom = 'ldap_'.$champ;
62 61
 		$val = trim(_request($nom));
63 62
 		if (preg_match('/^\w*$/', $val)) {
64 63
 			if ($val) {
65 64
 				$val = _q($val);
66 65
 			}
67 66
 		} else {
68
-			$val = 'array(' . _q(preg_split('/\W+/', $val)) . ')';
67
+			$val = 'array('._q(preg_split('/\W+/', $val)).')';
69 68
 		};
70 69
 		if ($val) {
71
-			$res .= "'$champ' => " . $val . ',';
70
+			$res .= "'$champ' => ".$val.',';
72 71
 		}
73 72
 	}
74 73
 	$conn .= "\$GLOBALS['ldap_champs'] = array($res);\n";
75 74
 
76
-	install_fichier_connexion(_DIR_CONNECT . _FILE_LDAP, $conn);
75
+	install_fichier_connexion(_DIR_CONNECT._FILE_LDAP, $conn);
77 76
 }
78 77
 
79 78
 function etape_ldap5_suite() {
@@ -86,7 +85,7 @@  discard block
 block discarded – undo
86 85
 	);
87 86
 
88 87
 	echo generer_form_ecrire('install', (
89
-		"<input type='hidden' name='etape' value='3' />" .
88
+		"<input type='hidden' name='etape' value='3' />".
90 89
 		"<input type='hidden' name='ldap_present' value='true' />"
91 90
 		. bouton_suivant()));
92 91
 
Please login to merge, or discard this patch.
ecrire/install/etape_chmod.php 1 patch
Spacing   +15 added lines, -16 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
 			$test_dir .= '/';
77 77
 		}
78 78
 		if (!in_array($test_dir, $GLOBALS['test_dirs'])) {
79
-			$GLOBALS['test_dirs'][] = _DIR_RACINE . $test_dir;
79
+			$GLOBALS['test_dirs'][] = _DIR_RACINE.$test_dir;
80 80
 		}
81 81
 	} else {
82 82
 		if (!_FILE_CONNECT) {
@@ -91,11 +91,11 @@  discard block
 block discarded – undo
91 91
 	foreach ($GLOBALS['test_dirs'] as $i => $my_dir) {
92 92
 		$test = test_ecrire($my_dir);
93 93
 		if (!$test) {
94
-			$m = preg_replace(',^' . _DIR_RACINE . ',', '', $my_dir);
94
+			$m = preg_replace(',^'._DIR_RACINE.',', '', $my_dir);
95 95
 			if (@file_exists($my_dir)) {
96
-				$bad_dirs['<li>' . $m . '</li>'] = 1;
96
+				$bad_dirs['<li>'.$m.'</li>'] = 1;
97 97
 			} else {
98
-				$absent_dirs['<li>' . $m . '</li>'] = 1;
98
+				$absent_dirs['<li>'.$m.'</li>'] = 1;
99 99
 			}
100 100
 		} else {
101 101
 			$chmod = max($chmod, $test);
@@ -105,21 +105,21 @@  discard block
 block discarded – undo
105 105
 	if ($bad_dirs || $absent_dirs) {
106 106
 		if (!_FILE_CONNECT) {
107 107
 			$titre = _T('dirs_preliminaire');
108
-			$continuer = ' ' . _T('dirs_commencer') . '.';
108
+			$continuer = ' '._T('dirs_commencer').'.';
109 109
 		} else {
110 110
 			$titre = _T('dirs_probleme_droits');
111 111
 		}
112 112
 
113 113
 
114
-		$res = "<div align='right'>" . menu_langues('var_lang_ecrire') . "</div>\n";
114
+		$res = "<div align='right'>".menu_langues('var_lang_ecrire')."</div>\n";
115 115
 
116 116
 		if ($bad_dirs) {
117 117
 			$res .=
118 118
 				_T(
119 119
 					'dirs_repertoires_suivants',
120 120
 					['bad_dirs' => implode("\n", array_keys($bad_dirs))]
121
-				) .
122
-				'<b>' . _T('login_recharger') . '</b>.';
121
+				).
122
+				'<b>'._T('login_recharger').'</b>.';
123 123
 		}
124 124
 
125 125
 		if ($absent_dirs) {
@@ -127,22 +127,21 @@  discard block
 block discarded – undo
127 127
 				_T(
128 128
 					'dirs_repertoires_absents',
129 129
 					['bad_dirs' => implode("\n", array_keys($absent_dirs))]
130
-				) .
131
-				'<b>' . _T('login_recharger') . '</b>.';
130
+				).
131
+				'<b>'._T('login_recharger').'</b>.';
132 132
 		}
133
-		$res = '<p>' . $continuer . $res . aider('install0', true) . '</p>';
133
+		$res = '<p>'.$continuer.$res.aider('install0', true).'</p>';
134 134
 
135 135
 		$t = _T('login_recharger');
136
-		$t = ($test_dir ? "<input type='hidden' name='test_dir' value='" . spip_htmlspecialchars($test_dir, ENT_QUOTES) . "' />" :
137
-				'')
136
+		$t = ($test_dir ? "<input type='hidden' name='test_dir' value='".spip_htmlspecialchars($test_dir, ENT_QUOTES)."' />" : '')
138 137
 			. "<input type='hidden' name='etape' value='chmod' />"
139
-			. "<div style='text-align: right'><input type='submit' value='" . attribut_html($t) . "' /></div>";
138
+			. "<div style='text-align: right'><input type='submit' value='".attribut_html($t)."' /></div>";
140 139
 
141
-		echo minipres($titre, $res . generer_form_ecrire('install', $t));
140
+		echo minipres($titre, $res.generer_form_ecrire('install', $t));
142 141
 	} else {
143 142
 		$deja = (_FILE_CONNECT && analyse_fichier_connection(_FILE_CONNECT));
144 143
 		if (!$deja) {
145
-			redirige_url_ecrire('install', 'etape=1&chmod=' . $chmod);
144
+			redirige_url_ecrire('install', 'etape=1&chmod='.$chmod);
146 145
 		} else {
147 146
 			redirige_url_ecrire();
148 147
 		}
Please login to merge, or discard this patch.
ecrire/install/etape_ldap2.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 	$adresse_ldap = filter_var($adresse_ldap, FILTER_SANITIZE_URL) ?: '';
49 49
 
50 50
 	$ldap_link = ldap_connect($adresse_ldap, $port_ldap);
51
-	$erreur = 'ldap_connect(' . spip_htmlspecialchars($adresse_ldap) . ', ' . spip_htmlspecialchars($port_ldap) . ')';
51
+	$erreur = 'ldap_connect('.spip_htmlspecialchars($adresse_ldap).', '.spip_htmlspecialchars($port_ldap).')';
52 52
 
53 53
 	if ($ldap_link) {
54 54
 		if (!ldap_set_option($ldap_link, LDAP_OPT_PROTOCOL_VERSION, $protocole_ldap)) {
@@ -56,18 +56,18 @@  discard block
 block discarded – undo
56 56
 			ldap_set_option($ldap_link, LDAP_OPT_PROTOCOL_VERSION, $protocole_ldap);
57 57
 		}
58 58
 		if ($tls && !ldap_start_tls($ldap_link)) {
59
-			$erreur = 'ldap_start_tls(' . spip_htmlspecialchars($ldap_link)
60
-				. ' ' . spip_htmlspecialchars($adresse_ldap)
61
-				. ', ' . spip_htmlspecialchars($port_ldap) . ')';
59
+			$erreur = 'ldap_start_tls('.spip_htmlspecialchars($ldap_link)
60
+				. ' '.spip_htmlspecialchars($adresse_ldap)
61
+				. ', '.spip_htmlspecialchars($port_ldap).')';
62 62
 			$ldap_link = false;
63 63
 		}
64 64
 		if ($ldap_link) {
65 65
 			$ldap_link = ldap_bind($ldap_link, $login_ldap, $pass_ldap);
66
-			$erreur = "ldap_bind('" . spip_htmlspecialchars($ldap_link)
67
-				. "', '" . spip_htmlspecialchars($login_ldap)
68
-				. "', '" . spip_htmlspecialchars($pass_ldap)
69
-				. "'): " . spip_htmlspecialchars($adresse_ldap)
70
-				. ', ' . spip_htmlspecialchars($port_ldap);
66
+			$erreur = "ldap_bind('".spip_htmlspecialchars($ldap_link)
67
+				. "', '".spip_htmlspecialchars($login_ldap)
68
+				. "', '".spip_htmlspecialchars($pass_ldap)
69
+				. "'): ".spip_htmlspecialchars($adresse_ldap)
70
+				. ', '.spip_htmlspecialchars($port_ldap);
71 71
 		}
72 72
 	}
73 73
 
@@ -75,22 +75,22 @@  discard block
 block discarded – undo
75 75
 		echo info_etape(
76 76
 			_T('titre_connexion_ldap'),
77 77
 			info_progression_etape(2, 'etape_ldap', 'install/')
78
-		),  _T('info_connexion_ldap_ok');
78
+		), _T('info_connexion_ldap_ok');
79 79
 		echo generer_form_ecrire('install', (
80 80
 			"\n<input type='hidden' name='etape' value='ldap3' />"
81
-			. "\n<input type='hidden' name='adresse_ldap' value=\"" . spip_htmlspecialchars($adresse_ldap) . '" />'
82
-			. "\n<input type='hidden' name='port_ldap' value=\"" . spip_htmlspecialchars($port_ldap) . '" />'
83
-			. "\n<input type='hidden' name='login_ldap' value=\"" . spip_htmlspecialchars($login_ldap) . '" />'
84
-			. "\n<input type='hidden' name='pass_ldap' value=\"" . spip_htmlspecialchars($pass_ldap) . '" />'
85
-			. "\n<input type='hidden' name='protocole_ldap' value=\"" . spip_htmlspecialchars($protocole_ldap) . '" />'
86
-			. "\n<input type='hidden' name='tls_ldap' value=\"" . spip_htmlspecialchars($tls_ldap) . '" />'
81
+			. "\n<input type='hidden' name='adresse_ldap' value=\"".spip_htmlspecialchars($adresse_ldap).'" />'
82
+			. "\n<input type='hidden' name='port_ldap' value=\"".spip_htmlspecialchars($port_ldap).'" />'
83
+			. "\n<input type='hidden' name='login_ldap' value=\"".spip_htmlspecialchars($login_ldap).'" />'
84
+			. "\n<input type='hidden' name='pass_ldap' value=\"".spip_htmlspecialchars($pass_ldap).'" />'
85
+			. "\n<input type='hidden' name='protocole_ldap' value=\"".spip_htmlspecialchars($protocole_ldap).'" />'
86
+			. "\n<input type='hidden' name='tls_ldap' value=\"".spip_htmlspecialchars($tls_ldap).'" />'
87 87
 			. bouton_suivant()));
88 88
 	} else {
89 89
 		echo info_etape(_T('titre_connexion_ldap')), info_progression_etape(1, 'etape_ldap', 'install/', true),
90
-			"<div class='error'><p>" . _T('avis_connexion_ldap_echec_1') . '</p>',
91
-			'<p>' . _T('avis_connexion_ldap_echec_2') .
92
-			"<br />\n" . _T('avis_connexion_ldap_echec_3') .
93
-			'<br /><br />' . $erreur . '<b> ?</b></p></div>';
90
+			"<div class='error'><p>"._T('avis_connexion_ldap_echec_1').'</p>',
91
+			'<p>'._T('avis_connexion_ldap_echec_2').
92
+			"<br />\n"._T('avis_connexion_ldap_echec_3').
93
+			'<br /><br />'.$erreur.'<b> ?</b></p></div>';
94 94
 	}
95 95
 
96 96
 	echo $minipage->installFinPage();
Please login to merge, or discard this patch.
ecrire/install/etape_3.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
 		= spip_connect_db($adresse_db, $port, $login_db, $pass_db, '', $server_db);
44 44
 
45 45
 	$GLOBALS['connexions'][$server_db][$GLOBALS['spip_sql_version']]
46
-		= $GLOBALS['spip_' . $server_db . '_functions_' . $GLOBALS['spip_sql_version']];
46
+		= $GLOBALS['spip_'.$server_db.'_functions_'.$GLOBALS['spip_sql_version']];
47 47
 
48 48
 	$fquery = sql_serveur('query', $server_db);
49 49
 	if ($choix_db == 'new_spip') {
@@ -53,13 +53,13 @@  discard block
 block discarded – undo
53 53
 			if (!$ok) {
54 54
 				$re = "Impossible de creer la base $re";
55 55
 				spip_log($re);
56
-				return '<p>' . _T('avis_connexion_erreur_creer_base') . "</p><!--\n$re\n-->";
56
+				return '<p>'._T('avis_connexion_erreur_creer_base')."</p><!--\n$re\n-->";
57 57
 			}
58 58
 		} else {
59 59
 			$re = "Le nom de la base doit correspondre a $re";
60 60
 			spip_log($re);
61 61
 
62
-			return '<p>' . _T('avis_connexion_erreur_nom_base') . "</p><!--\n$re\n-->";
62
+			return '<p>'._T('avis_connexion_erreur_nom_base')."</p><!--\n$re\n-->";
63 63
 		}
64 64
 	}
65 65
 
@@ -70,14 +70,14 @@  discard block
 block discarded – undo
70 70
 		= spip_connect_db($adresse_db, $port, $login_db, $pass_db, $sel_db, $server_db);
71 71
 
72 72
 	$GLOBALS['connexions'][$server_db][$GLOBALS['spip_sql_version']]
73
-		= $GLOBALS['spip_' . $server_db . '_functions_' . $GLOBALS['spip_sql_version']];
73
+		= $GLOBALS['spip_'.$server_db.'_functions_'.$GLOBALS['spip_sql_version']];
74 74
 
75 75
 	// Completer le tableau decrivant la connexion
76 76
 
77 77
 	$GLOBALS['connexions'][$server_db]['prefixe'] = $table_prefix;
78 78
 	$GLOBALS['connexions'][$server_db]['db'] = $sel_db;
79 79
 
80
-	$old = sql_showbase($table_prefix . '_meta', $server_db);
80
+	$old = sql_showbase($table_prefix.'_meta', $server_db);
81 81
 	if ($old) {
82 82
 		$old = sql_fetch($old, $server_db);
83 83
 	}
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 				$charset['charset'];
97 97
 			$charsetbase = $charset['charset'];
98 98
 		} else {
99
-			spip_log(_DEFAULT_CHARSET . ' inconnu du serveur SQL');
99
+			spip_log(_DEFAULT_CHARSET.' inconnu du serveur SQL');
100 100
 			$charsetbase = 'standard';
101 101
 		}
102 102
 		spip_log("Creation des tables. Codage $charsetbase");
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
 		if ($r) {
147 147
 			$r = sql_fetch($r, $server_db);
148 148
 		}
149
-		$version_installee = $r ? (double)$r['valeur'] : 0;
149
+		$version_installee = $r ? (double) $r['valeur'] : 0;
150 150
 		if (!$version_installee || $GLOBALS['spip_version_base'] < $version_installee) {
151 151
 			$fupdateq(
152 152
 				'spip_meta',
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
 				'',
156 156
 				$server_db
157 157
 			);
158
-			spip_log('nouvelle version installee: ' . $GLOBALS['spip_version_base']);
158
+			spip_log('nouvelle version installee: '.$GLOBALS['spip_version_base']);
159 159
 		}
160 160
 		// eliminer la derniere operation d'admin mal terminee
161 161
 		// notamment la mise a jour
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
 	if ($chmod_db) {
183 183
 		install_fichier_connexion(
184 184
 			_FILE_CHMOD_TMP,
185
-			"if (!defined('_SPIP_CHMOD')) define('_SPIP_CHMOD', " . sprintf('0%3o', $chmod_db) . ");\n"
185
+			"if (!defined('_SPIP_CHMOD')) define('_SPIP_CHMOD', ".sprintf('0%3o', $chmod_db).");\n"
186 186
 		);
187 187
 	}
188 188
 
@@ -245,16 +245,16 @@  discard block
 block discarded – undo
245 245
 
246 246
 
247 247
 function install_premier_auteur($email, $login, $nom, #[\SensitiveParameter] $pass, $hidden, $auteur_obligatoire) {
248
-	return info_progression_etape(3, 'etape_', 'install/') .
248
+	return info_progression_etape(3, 'etape_', 'install/').
249 249
 	info_etape(
250 250
 		_T('info_informations_personnelles'),
251
-		'<b>' . _T('texte_informations_personnelles_1') . '</b>' .
252
-		aider('install5', true) .
253
-		'<p>' .
251
+		'<b>'._T('texte_informations_personnelles_1').'</b>'.
252
+		aider('install5', true).
253
+		'<p>'.
254 254
 		($auteur_obligatoire ?
255 255
 			''
256 256
 			:
257
-			_T('texte_informations_personnelles_2') . ' ' . _T('info_laisser_champs_vides')
257
+			_T('texte_informations_personnelles_2').' '._T('info_laisser_champs_vides')
258 258
 		)
259 259
 	)
260 260
 	. generer_form_ecrire('install', (
@@ -264,12 +264,12 @@  discard block
 block discarded – undo
264 264
 			_T('info_identification_publique'),
265 265
 			[
266 266
 				'nom' => [
267
-					'label' => '<b>' . _T('entree_signature') . "</b><br />\n" . _T('entree_nom_pseudo_1') . "\n",
267
+					'label' => '<b>'._T('entree_signature')."</b><br />\n"._T('entree_nom_pseudo_1')."\n",
268 268
 					'valeur' => $nom,
269 269
 					'required' => $auteur_obligatoire,
270 270
 				],
271 271
 				'email' => [
272
-					'label' => '<b>' . _T('entree_adresse_email') . "</b>\n",
272
+					'label' => '<b>'._T('entree_adresse_email')."</b>\n",
273 273
 					'valeur' => $email,
274 274
 				]
275 275
 			]
@@ -279,23 +279,23 @@  discard block
 block discarded – undo
279 279
 			_T('entree_identifiants_connexion'),
280 280
 			[
281 281
 				'login' => [
282
-					'label' => '<b>' . _T('entree_login') . "</b><br />\n" . _T(
282
+					'label' => '<b>'._T('entree_login')."</b><br />\n"._T(
283 283
 						'info_login_trop_court_car_pluriel',
284 284
 						['nb' => _LOGIN_TROP_COURT]
285
-					) . "\n",
285
+					)."\n",
286 286
 					'valeur' => $login,
287 287
 					'required' => $auteur_obligatoire,
288 288
 				],
289 289
 				'pass' => [
290
-					'label' => '<b>' . _T('entree_mot_passe') . "</b><br />\n" . _T(
290
+					'label' => '<b>'._T('entree_mot_passe')."</b><br />\n"._T(
291 291
 						'info_passe_trop_court_car_pluriel',
292 292
 						['nb' => _PASS_LONGUEUR_MINI]
293
-					) . "\n",
293
+					)."\n",
294 294
 					'valeur' => $pass,
295 295
 					'required' => $auteur_obligatoire,
296 296
 				],
297 297
 				'pass_verif' => [
298
-					'label' => '<b>' . _T('info_confirmer_passe') . "</b><br />\n",
298
+					'label' => '<b>'._T('info_confirmer_passe')."</b><br />\n",
299 299
 					'valeur' => $pass,
300 300
 					'required' => $auteur_obligatoire,
301 301
 				]
@@ -339,9 +339,9 @@  discard block
 block discarded – undo
339 339
 
340 340
 		if ($res) {
341 341
 			$res = info_progression_etape(2, 'etape_', 'install/', true)
342
-				. "<div class='error'><h3>" . _T('avis_operation_echec') . '</h3>'
342
+				. "<div class='error'><h3>"._T('avis_operation_echec').'</h3>'
343 343
 				. $res
344
-				. '<p>' . _T('texte_operation_echec') . '</p>'
344
+				. '<p>'._T('texte_operation_echec').'</p>'
345 345
 				. '</div>';
346 346
 		}
347 347
 	} else {
@@ -365,7 +365,7 @@  discard block
 block discarded – undo
365 365
 
366 366
 		$hidden = predef_ou_cache($adresse_db, $login_db, $pass_db, $server_db)
367 367
 			. (defined('_INSTALL_NAME_DB') ? ''
368
-				: "\n<input type='hidden' name='sel_db' value=\"" . spip_htmlspecialchars($sel_db) . '" />');
368
+				: "\n<input type='hidden' name='sel_db' value=\"".spip_htmlspecialchars($sel_db).'" />');
369 369
 
370 370
 		$auteur_obligatoire = ($ldap_present ? 0 : !sql_countsel('spip_auteurs', '', '', '', $server_db));
371 371
 
Please login to merge, or discard this patch.
ecrire/public.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -29,9 +29,9 @@  discard block
 block discarded – undo
29 29
 	if (!defined('_DIR_RESTREINT_ABS')) {
30 30
 		if (
31 31
 			defined('_DIR_RESTREINT')
32
-			&& @file_exists(_ROOT_RESTREINT . 'inc_version.php')
32
+			&& @file_exists(_ROOT_RESTREINT.'inc_version.php')
33 33
 		) {
34
-			include_once _ROOT_RESTREINT . 'inc_version.php';
34
+			include_once _ROOT_RESTREINT.'inc_version.php';
35 35
 		} else {
36 36
 			die('inc_version absent ?');
37 37
 		}
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 		} // fond demande dans l'url par page=xxxx ?
43 43
 		else {
44 44
 			if (isset($_GET[_SPIP_PAGE])) {
45
-				$fond = (string)$_GET[_SPIP_PAGE];
45
+				$fond = (string) $_GET[_SPIP_PAGE];
46 46
 
47 47
 				// Securite
48 48
 				if (
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
 			// lancer les taches sur affichage final, comme le cron
102 102
 			// mais sans rien afficher
103 103
 			$GLOBALS['html'] = false; // ne rien afficher
104
-			pipeline('affichage_final' . _PIPELINE_SUFFIX, '');
104
+			pipeline('affichage_final'._PIPELINE_SUFFIX, '');
105 105
 			exit; // le hit est fini !
106 106
 		}
107 107
 	}
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
 	// Content-Type ?
119 119
 	if (!isset($page['entetes']['Content-Type'])) {
120 120
 		$charset = $GLOBALS['meta']['charset'] ?? 'utf-8';
121
-		$page['entetes']['Content-Type'] = 'text/html; charset=' . $charset;
121
+		$page['entetes']['Content-Type'] = 'text/html; charset='.$charset;
122 122
 		$html = true;
123 123
 	} else {
124 124
 		$html = preg_match(',^\s*text/html,', $page['entetes']['Content-Type']);
@@ -144,11 +144,11 @@  discard block
 block discarded – undo
144 144
 
145 145
 	// traitements sur les entetes avant envoi
146 146
 	// peut servir pour le plugin de stats
147
-	$page['entetes'] = pipeline('affichage_entetes_final' . _PIPELINE_SUFFIX, $page['entetes']);
147
+	$page['entetes'] = pipeline('affichage_entetes_final'._PIPELINE_SUFFIX, $page['entetes']);
148 148
 
149 149
 
150 150
 	// eval $page et affecte $res
151
-	include _ROOT_RESTREINT . 'public/evaluer_page.php';
151
+	include _ROOT_RESTREINT.'public/evaluer_page.php';
152 152
 	envoyer_entetes($page['entetes']);
153 153
 	if ($res === false) {
154 154
 		include_spip('inc/autoriser');
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
 	//
168 168
 	// (c'est ici qu'on fait var_recherche, validation, boutons d'admin,
169 169
 	// cf. public/assembler.php)
170
-	echo pipeline('affichage_final' . _PIPELINE_SUFFIX, $page['texte']);
170
+	echo pipeline('affichage_final'._PIPELINE_SUFFIX, $page['texte']);
171 171
 
172 172
 	if ($lang) {
173 173
 		lang_select();
@@ -183,7 +183,7 @@  discard block
 block discarded – undo
183 183
 		if ($html && ($affiche_boutons_admin || $debug)) {
184 184
 			$var_mode_affiche = _request('var_mode_affiche');
185 185
 			$var_mode_objet = _request('var_mode_objet');
186
-			$GLOBALS['debug_objets'][$var_mode_affiche][$var_mode_objet . 'tout'] = ($var_mode_affiche == 'validation' ? $page['texte'] : '');
186
+			$GLOBALS['debug_objets'][$var_mode_affiche][$var_mode_objet.'tout'] = ($var_mode_affiche == 'validation' ? $page['texte'] : '');
187 187
 			echo erreur_squelette(false);
188 188
 		}
189 189
 	} else {
Please login to merge, or discard this patch.
ecrire/public/cacher.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
 function generer_nom_fichier_cache($contexte, $page) {
27 27
 	$u = md5(var_export([$contexte, $page], true));
28 28
 
29
-	return $u . '.cache';
29
+	return $u.'.cache';
30 30
 }
31 31
 
32 32
 /**
@@ -58,10 +58,10 @@  discard block
 block discarded – undo
58 58
 	}
59 59
 	else {
60 60
 		// en lecture on essaye pas de creer les repertoires, on va au plus vite
61
-		$rep = _DIR_CACHE . "calcul/$d/";
61
+		$rep = _DIR_CACHE."calcul/$d/";
62 62
 	}
63 63
 
64
-	return $rep . $u . '.cache';
64
+	return $rep.$u.'.cache';
65 65
 }
66 66
 
67 67
 /**
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
 		);
114 114
 	}
115 115
 
116
-	return crc32($GLOBALS['meta']['cache_signature'] . $page['texte']);
116
+	return crc32($GLOBALS['meta']['cache_signature'].$page['texte']);
117 117
 }
118 118
 
119 119
 /**
@@ -263,7 +263,7 @@  discard block
 block discarded – undo
263 263
 		// "cache sessionne" ; sa date indique la date de validite
264 264
 		// des caches sessionnes
265 265
 		if (!$tmp = lire_cache($chemin_cache)) {
266
-			spip_log('Creation cache sessionne ' . $chemin_cache);
266
+			spip_log('Creation cache sessionne '.$chemin_cache);
267 267
 			$tmp = [
268 268
 				'invalideurs' => ['session' => ''],
269 269
 				'lastmodified' => $_SERVER['REQUEST_TIME']
@@ -289,8 +289,8 @@  discard block
 block discarded – undo
289 289
 	// l'enregistrer, compresse ou non...
290 290
 	$ok = ecrire_cache($chemin_cache, $pagez);
291 291
 
292
-	spip_log((_IS_BOT ? 'Bot:' : '') . "Creation du cache $chemin_cache pour "
293
-		. $page['entetes']['X-Spip-Cache'] . ' secondes' . ($ok ? '' : ' (erreur!)'), _LOG_INFO);
292
+	spip_log((_IS_BOT ? 'Bot:' : '')."Creation du cache $chemin_cache pour "
293
+		. $page['entetes']['X-Spip-Cache'].' secondes'.($ok ? '' : ' (erreur!)'), _LOG_INFO);
294 294
 
295 295
 	// Inserer ses invalideurs
296 296
 	include_spip('inc/invalideur');
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
 function nettoyer_petit_cache($prefix, $duree = 300) {
310 310
 	// determiner le repertoire a purger : 'tmp/CACHE/rech/'
311 311
 	$dircache = sous_repertoire(_DIR_CACHE, $prefix);
312
-	if (spip_touch($dircache . 'purger_' . $prefix, $duree, true)) {
312
+	if (spip_touch($dircache.'purger_'.$prefix, $duree, true)) {
313 313
 		foreach (preg_files($dircache, '[.]txt$') as $f) {
314 314
 			if ($_SERVER['REQUEST_TIME'] - (@file_exists($f) ? @filemtime($f) : 0) > $duree) {
315 315
 				spip_unlink($f);
@@ -402,9 +402,9 @@  discard block
 block discarded – undo
402 402
 		include_spip('inc/invalideur');
403 403
 		retire_caches($chemin_cache);
404 404
 		# API invalideur inutile
405
-		supprimer_fichier(_DIR_CACHE . $chemin_cache);
405
+		supprimer_fichier(_DIR_CACHE.$chemin_cache);
406 406
 		if (isset($chemin_cache_session) && $chemin_cache_session) {
407
-			supprimer_fichier(_DIR_CACHE . $chemin_cache_session);
407
+			supprimer_fichier(_DIR_CACHE.$chemin_cache_session);
408 408
 		}
409 409
 	}
410 410
 
@@ -420,9 +420,9 @@  discard block
 block discarded – undo
420 420
 		$page = ['contexte_implicite' => $contexte_implicite]; // ignorer le cache deja lu
421 421
 		include_spip('inc/invalideur');
422 422
 		retire_caches($chemin_cache); # API invalideur inutile
423
-		supprimer_fichier(_DIR_CACHE . $chemin_cache);
423
+		supprimer_fichier(_DIR_CACHE.$chemin_cache);
424 424
 		if (isset($chemin_cache_session) && $chemin_cache_session) {
425
-			supprimer_fichier(_DIR_CACHE . $chemin_cache_session);
425
+			supprimer_fichier(_DIR_CACHE.$chemin_cache_session);
426 426
 		}
427 427
 	}
428 428
 
Please login to merge, or discard this patch.
ecrire/public/assembler.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 
39 39
 	$GLOBALS['contexte'] = calculer_contexte();
40 40
 	$page = ['contexte_implicite' => calculer_contexte_implicite()];
41
-	$page['contexte_implicite']['cache'] = $fond . preg_replace(
41
+	$page['contexte_implicite']['cache'] = $fond.preg_replace(
42 42
 		',\.[a-zA-Z0-9]*$,',
43 43
 		'',
44 44
 		preg_replace('/[?].*$/', '', $GLOBALS['REQUEST_URI'])
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 			if ($page === '') {
140 140
 				$erreur = _T(
141 141
 					'info_erreur_squelette2',
142
-					['fichier' => spip_htmlspecialchars($fond) . '.' . _EXTENSION_SQUELETTES]
142
+					['fichier' => spip_htmlspecialchars($fond).'.'._EXTENSION_SQUELETTES]
143 143
 				);
144 144
 				erreur_squelette($erreur);
145 145
 				// eviter des erreurs strictes ensuite sur $page['cle'] en PHP >= 5.4
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
 		and !isset($_SERVER['HTTP_IF_MODIFIED_SINCE'])
183 183
 		and !isset($page['entetes']['Last-Modified'])
184 184
 	) {
185
-		$page['entetes']['Last-Modified'] = gmdate('D, d M Y H:i:s', $lastmodified) . ' GMT';
185
+		$page['entetes']['Last-Modified'] = gmdate('D, d M Y H:i:s', $lastmodified).' GMT';
186 186
 	}
187 187
 
188 188
 	// fermer la connexion apres les headers si requete HEAD
@@ -245,7 +245,7 @@  discard block
 block discarded – undo
245 245
 		'spip_version_code' => $GLOBALS['spip_version_code'],
246 246
 	];
247 247
 	if (isset($_SERVER['HTTP_X_FORWARDED_HOST'])) {
248
-		$contexte_implicite['host'] .= '|' . $_SERVER['HTTP_X_FORWARDED_HOST'];
248
+		$contexte_implicite['host'] .= '|'.$_SERVER['HTTP_X_FORWARDED_HOST'];
249 249
 	}
250 250
 
251 251
 	return $contexte_implicite;
@@ -577,7 +577,7 @@  discard block
 block discarded – undo
577 577
 			}
578 578
 		}
579 579
 		if (is_null($id)) {
580
-			$msg = "modeles/$modele : " . _T('zbug_parametres_inclus_incorrects', ['param' => "id/$primary"]);
580
+			$msg = "modeles/$modele : "._T('zbug_parametres_inclus_incorrects', ['param' => "id/$primary"]);
581 581
 			erreur_squelette($msg);
582 582
 			// on passe id=0 au routeur pour tomber sur le modele par defaut et eviter une seconde erreur sur un modele inexistant
583 583
 			$id = 0;
@@ -622,7 +622,7 @@  discard block
 block discarded – undo
622 622
 		}
623 623
 
624 624
 		if (preg_match(',^[a-z0-9_]+$,', $soustype)) {
625
-			if (!trouve_modele($fond = ($type . '_' . $soustype))) {
625
+			if (!trouve_modele($fond = ($type.'_'.$soustype))) {
626 626
 				$fond = '';
627 627
 				$class = $soustype;
628 628
 			}
@@ -637,7 +637,7 @@  discard block
 block discarded – undo
637 637
 
638 638
 		return false;
639 639
 	}
640
-	$fond = 'modeles/' . $fond;
640
+	$fond = 'modeles/'.$fond;
641 641
 	// Creer le contexte
642 642
 	$contexte = $env;
643 643
 	$contexte['dir_racine'] = _DIR_RACINE; # eviter de mixer un cache racine et un cache ecrire (meme si pour l'instant les modeles ne sont pas caches, le resultat etant different il faut que le contexte en tienne compte
@@ -678,7 +678,7 @@  discard block
 block discarded – undo
678 678
 	// sinon, s'il y a un lien, on l'ajoute classiquement
679 679
 	if (
680 680
 		strstr(
681
-			' ' . ($classes = extraire_attribut($retour, 'class')) . ' ',
681
+			' '.($classes = extraire_attribut($retour, 'class')).' ',
682 682
 			'spip_lien_ok'
683 683
 		)
684 684
 	) {
@@ -689,7 +689,7 @@  discard block
 block discarded – undo
689 689
 		);
690 690
 	} else {
691 691
 		if ($lien) {
692
-			$retour = '<a href="' . $lien['href'] . '" class="' . $lien['class'] . '">' . $retour . '</a>';
692
+			$retour = '<a href="'.$lien['href'].'" class="'.$lien['class'].'">'.$retour.'</a>';
693 693
 		}
694 694
 	}
695 695
 
@@ -712,7 +712,7 @@  discard block
 block discarded – undo
712 712
 		return $page;
713 713
 	}
714 714
 	// eval $page et affecte $res
715
-	include _ROOT_RESTREINT . 'public/evaluer_page.php';
715
+	include _ROOT_RESTREINT.'public/evaluer_page.php';
716 716
 
717 717
 	// Lever un drapeau (global) si le fond utilise #SESSION
718 718
 	// a destination de public/parametrer
@@ -779,16 +779,16 @@  discard block
 block discarded – undo
779 779
 			if (($pos = strpos($head, '<head>')) !== false) {
780 780
 				$head = substr_replace($head, $base, $pos + 6, 0);
781 781
 			} elseif (preg_match(',<head[^>]*>,i', $head, $r)) {
782
-				$head = str_replace($r[0], $r[0] . $base, $head);
782
+				$head = str_replace($r[0], $r[0].$base, $head);
783 783
 			}
784
-			$texte = $head . substr($texte, $poshead);
784
+			$texte = $head.substr($texte, $poshead);
785 785
 		}
786 786
 		if ($href_base) {
787 787
 			// gerer les ancres
788 788
 			$base = $_SERVER['REQUEST_URI'];
789 789
 			// pas de guillemets ni < dans l'URL qu'on insere dans le HTML
790 790
 			if (strpos($base, "'") or strpos($base, '"') or strpos($base, '<')) {
791
-				$base = str_replace(["'",'"','<'], ['%27','%22','%3C'], $base);
791
+				$base = str_replace(["'", '"', '<'], ['%27', '%22', '%3C'], $base);
792 792
 			}
793 793
 			if (strpos($texte, "href='#") !== false) {
794 794
 				$texte = str_replace("href='#", "href='$base#", $texte);
Please login to merge, or discard this patch.
ecrire/public/decompiler.php 1 patch
Spacing   +18 added lines, -19 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
 	$type .= ($struct->type_requete ?: $struct->table_optionnelle);
31 31
 
32 32
 	if ($struct->jointures_explicites) {
33
-		$type .= ' ' . $struct->jointures_explicites;
33
+		$type .= ' '.$struct->jointures_explicites;
34 34
 	}
35 35
 	if ($struct->table_optionnelle) {
36 36
 		$type .= '?';
@@ -39,11 +39,11 @@  discard block
 block discarded – undo
39 39
 
40 40
 	$crit = $struct->param;
41 41
 	if ($crit && !is_array($crit[0])) {
42
-		$type = strtolower($type) . array_shift($crit);
42
+		$type = strtolower($type).array_shift($crit);
43 43
 	}
44 44
 	$crit = decompiler_criteres($struct, $fmt, $prof);
45 45
 
46
-	$f = 'format_boucle_' . $fmt;
46
+	$f = 'format_boucle_'.$fmt;
47 47
 
48 48
 	return $f($preaff, $avant, $nom, $type, $crit, $milieu, $apres, $altern, $postaff, $prof);
49 49
 }
@@ -56,21 +56,20 @@  discard block
 block discarded – undo
56 56
 			$res[] = decompiler_($v, $fmt, $prof);
57 57
 		}
58 58
 	}
59
-	$file = is_string($struct->texte) ? $struct->texte :
60
-		decompiler_($struct->texte, $fmt, $prof);
61
-	$f = 'format_inclure_' . $fmt;
59
+	$file = is_string($struct->texte) ? $struct->texte : decompiler_($struct->texte, $fmt, $prof);
60
+	$f = 'format_inclure_'.$fmt;
62 61
 
63 62
 	return $f($file, $res, $prof);
64 63
 }
65 64
 
66 65
 function decompiler_texte($struct, $fmt = '', $prof = 0) {
67
-	$f = 'format_texte_' . $fmt;
66
+	$f = 'format_texte_'.$fmt;
68 67
 
69 68
 	return strlen($struct->texte) ? $f($struct->texte, $prof) : '';
70 69
 }
71 70
 
72 71
 function decompiler_polyglotte($struct, $fmt = '', $prof = 0) {
73
-	$f = 'format_polyglotte_' . $fmt;
72
+	$f = 'format_polyglotte_'.$fmt;
74 73
 
75 74
 	return $f($struct->traductions, $prof);
76 75
 }
@@ -83,7 +82,7 @@  discard block
 block discarded – undo
83 82
 
84 83
 	$filtres = decompiler_liste($struct->param, $fmt, $prof);
85 84
 
86
-	$f = 'format_idiome_' . $fmt;
85
+	$f = 'format_idiome_'.$fmt;
87 86
 
88 87
 	return $f($struct->nom_champ, $struct->module, $args, $filtres, $prof);
89 88
 }
@@ -98,7 +97,7 @@  discard block
 block discarded – undo
98 97
 		}
99 98
 		$filtres = decompiler_liste($p, $fmt, $prof);
100 99
 	}
101
-	$f = 'format_champ_' . $fmt;
100
+	$f = 'format_champ_'.$fmt;
102 101
 
103 102
 	return $f($struct->nom_champ, $struct->nom_boucle, $struct->etoile, $avant, $apres, $args, $filtres, $prof);
104 103
 }
@@ -107,7 +106,7 @@  discard block
 block discarded – undo
107 106
 	if (!is_array($sources)) {
108 107
 		return '';
109 108
 	}
110
-	$f = 'format_liste_' . $fmt;
109
+	$f = 'format_liste_'.$fmt;
111 110
 	$res = '';
112 111
 	foreach ($sources as $arg) {
113 112
 		if (!is_array($arg)) {
@@ -124,7 +123,7 @@  discard block
 block discarded – undo
124 123
 				&& strlen($v[0]->apres) == 1
125 124
 				&& $v[0]->apres == $v[0]->avant
126 125
 			) {
127
-				$args[] = $v[0]->avant . $v[0]->texte . $v[0]->apres;
126
+				$args[] = $v[0]->avant.$v[0]->texte.$v[0]->apres;
128 127
 			} else {
129 128
 				$args[] = decompiler_($v, $fmt, 0 - $prof);
130 129
 			}
@@ -147,7 +146,7 @@  discard block
 block discarded – undo
147 146
 		return '';
148 147
 	}
149 148
 	$res = '';
150
-	$f = 'format_critere_' . $fmt;
149
+	$f = 'format_critere_'.$fmt;
151 150
 	foreach ($sources as $crit) {
152 151
 		if (!is_array($crit)) {
153 152
 			continue;
@@ -160,13 +159,13 @@  discard block
 block discarded – undo
160 159
 				&& $v[0]->type == 'texte'
161 160
 				&& $v[0]->apres
162 161
 			) {
163
-				$args[] = [['texte', ($v[0]->apres . $v[0]->texte . $v[0]->apres)]];
162
+				$args[] = [['texte', ($v[0]->apres.$v[0]->texte.$v[0]->apres)]];
164 163
 			} else {
165 164
 				$res2 = [];
166 165
 				foreach ($v as $k => $p) {
167 166
 					if (
168 167
 						isset($p->type)
169
-						&& function_exists($d = 'decompiler_' . $p->type)
168
+						&& function_exists($d = 'decompiler_'.$p->type)
170 169
 					) {
171 170
 						$r = $d($p, $fmt, (0 - $prof));
172 171
 						$res2[] = [$p->type, $r];
@@ -194,7 +193,7 @@  discard block
 block discarded – undo
194 193
 		if (!isset($p->type)) {
195 194
 			continue;
196 195
 		} #??????
197
-		$d = 'decompiler_' . $p->type;
196
+		$d = 'decompiler_'.$p->type;
198 197
 		$next = $liste[$k + 1] ?? false;
199 198
 		// Forcer le champ etendu si son source (pas les reecritures)
200 199
 		// contenait des args et s'il est suivi d'espaces,
@@ -219,16 +218,16 @@  discard block
 block discarded – undo
219 218
 		}
220 219
 		$contenu[] = [$d($p, $fmt, $prof2), $p->type];
221 220
 	}
222
-	$f = 'format_suite_' . $fmt;
221
+	$f = 'format_suite_'.$fmt;
223 222
 
224 223
 	return $f($contenu);
225 224
 }
226 225
 
227 226
 function public_decompiler($liste, $fmt = '', $prof = 0, $quoi = '') {
228
-	if (!include_spip('public/format_' . $fmt)) {
227
+	if (!include_spip('public/format_'.$fmt)) {
229 228
 		return "'$fmt'?";
230 229
 	}
231
-	$f = 'decompiler_' . $quoi;
230
+	$f = 'decompiler_'.$quoi;
232 231
 
233 232
 	return $f($liste, $fmt, $prof);
234 233
 }
Please login to merge, or discard this patch.