Completed
Branch master (47aeae)
by cam
06:39
created
ecrire/public/parametrer.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -231,7 +231,7 @@
 block discarded – undo
231 231
  *
232 232
  * @uses public_tester_redirection_dist()
233 233
  * @param string $fond
234
- * @param array $contexte
234
+ * @param string $contexte
235 235
  * @param string $connect
236 236
  * @return array|bool
237 237
  */
Please login to merge, or discard this patch.
ecrire/public/quete.php 1 patch
Doc Comments   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -28,9 +28,9 @@  discard block
 block discarded – undo
28 28
 /**
29 29
  * Retourne l'URL de redirection d'un article virtuel, seulement si il est publié
30 30
  *
31
- * @param $id_article
32
- * @param $connect
33
- * @return array|bool|null
31
+ * @param integer $id_article
32
+ * @param string $connect
33
+ * @return string
34 34
  */
35 35
 function quete_virtuel($id_article, $connect) {
36 36
 	return sql_getfetsel(
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
  * @uses quete_parent_lang()
123 123
  *
124 124
  * @param int $id_article
125
- * @param $serveur
125
+ * @param string $serveur
126 126
  * @return int
127 127
  */
128 128
 function quete_rubrique($id_article, $serveur) {
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
  *
286 286
  * @param int $id_document
287 287
  * @param string $serveur
288
- * @return array|bool|null
288
+ * @return string
289 289
  */
290 290
 function quete_fichier($id_document, $serveur = '') {
291 291
 	return sql_getfetsel('fichier', 'spip_documents', ('id_document=' . intval($id_document)), '', array(), '', '', $serveur);
@@ -307,8 +307,8 @@  discard block
 block discarded – undo
307 307
  *
308 308
  * http://code.spip.net/@quete_meta
309 309
  *
310
- * @param $nom
311
- * @param $serveur
310
+ * @param string $nom
311
+ * @param string $serveur
312 312
  * @return array|bool|null
313 313
  */
314 314
 function quete_meta($nom, $serveur) {
Please login to merge, or discard this patch.
ecrire/public/references.php 1 patch
Doc Comments   +16 added lines, -2 removed lines patch added patch discarded remove patch
@@ -293,7 +293,7 @@  discard block
 block discarded – undo
293 293
  *           est dans une autre table et construit la jointure dessus
294 294
  *         - liste (table, champ, fonction) idem, mais en passant un
295 295
  *           nom de fonction qui s'occupera de créer la jointure.
296
- * @return array
296
+ * @return string[]
297 297
  *     Liste (nom du champ alias, nom du champ). Le nom du champ alias
298 298
  *     est une expression pour le SELECT de la boucle du style "mots.titre AS titre_mot"
299 299
  **/
@@ -471,7 +471,7 @@  discard block
 block discarded – undo
471 471
  *     Nom de la balise
472 472
  * @param Champ $p
473 473
  *     AST au niveau de la balise
474
- * @return string
474
+ * @return Champ
475 475
  *     Code PHP pour d'exécution de la balise et de ses filtres
476 476
  **/
477 477
 function calculer_balise_DEFAUT_dist($nom, $p) {
@@ -755,6 +755,9 @@  discard block
 block discarded – undo
755 755
 //  - deux etoiles => pas de securite non plus !
756 756
 //
757 757
 // http://code.spip.net/@applique_filtres
758
+/**
759
+ * @param Champ $p
760
+ */
758 761
 function applique_filtres($p) {
759 762
 
760 763
 	// Traitements standards (cf. supra)
@@ -829,6 +832,9 @@  discard block
 block discarded – undo
829 832
 
830 833
 // Filtres et,ou,oui,non,sinon,xou,xor,and,or,not,yes
831 834
 // et comparateurs
835
+/**
836
+ * @param string $arg
837
+ */
832 838
 function filtre_logique($fonc, $code, $arg) {
833 839
 
834 840
 	switch (true) {
@@ -852,6 +858,9 @@  discard block
 block discarded – undo
852 858
 }
853 859
 
854 860
 // http://code.spip.net/@compose_filtres_args
861
+/**
862
+ * @param string $sep
863
+ */
855 864
 function compose_filtres_args($p, $args, $sep) {
856 865
 	$arglist = "";
857 866
 	foreach ($args as $arg) {
@@ -899,6 +908,11 @@  discard block
 block discarded – undo
899 908
 //
900 909
 
901 910
 // http://code.spip.net/@rindex_pile
911
+/**
912
+ * @param Champ $p
913
+ * @param string $champ
914
+ * @param string $motif
915
+ */
902 916
 function rindex_pile($p, $champ, $motif) {
903 917
 	$n = 0;
904 918
 	$b = $p->id_boucle;
Please login to merge, or discard this patch.
ecrire/public/sandbox.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -158,7 +158,7 @@
 block discarded – undo
158 158
  * @param string $corps
159 159
  * @param array $filtres
160 160
  *     Tableau de filtres à appliquer.
161
- * @return mixed|string
161
+ * @return string
162 162
  */
163 163
 function sandbox_filtrer_squelette($skel, $corps, $filtres) {
164 164
 	$series_filtres = func_get_args();
Please login to merge, or discard this patch.
ecrire/public/styliser_par_z.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -236,7 +236,7 @@
 block discarded – undo
236 236
  * @param string $type
237 237
  * @param string $ext
238 238
  * @param bool $echafauder
239
- * @return mixed
239
+ * @return string|boolean
240 240
  */
241 241
 function z_contenu_disponible($prefix_path, $z_contenu, $type, $ext, $echafauder = true) {
242 242
 	if ($d = z_trouver_bloc($prefix_path, $z_contenu, $type, $ext)) {
Please login to merge, or discard this patch.
ecrire/public/tracer.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -41,6 +41,9 @@
 block discarded – undo
41 41
 }
42 42
 
43 43
 // http://code.spip.net/@trace_query_chrono
44
+/**
45
+ * @param string $m2
46
+ */
44 47
 function trace_query_chrono($m1, $m2, $query, $result, $serveur = '') {
45 48
 	include_spip('inc/filtres_mini');
46 49
 	static $tt = 0, $nb = 0;
Please login to merge, or discard this patch.
ecrire/req/pg.exp.php 1 patch
Doc Comments   +32 added lines, -1 removed lines patch added patch discarded remove patch
@@ -132,6 +132,11 @@  discard block
 block discarded – undo
132 132
 
133 133
 // Par ou ca passe une fois les traductions faites
134 134
 // http://code.spip.net/@spip_pg_trace_query
135
+/**
136
+ * @param string $query
137
+ *
138
+ * @return resource
139
+ */
135 140
 function spip_pg_trace_query($query, $serveur = '') {
136 141
 	$connexion = &$GLOBALS['connexions'][$serveur ? strtolower($serveur) : 0];
137 142
 	$prefixe = $connexion['prefixe'];
@@ -290,6 +295,9 @@  discard block
 block discarded – undo
290 295
 }
291 296
 
292 297
 // http://code.spip.net/@spip_pg_alter_change
298
+/**
299
+ * @param string $arg
300
+ */
293 301
 function spip_pg_alter_change($table, $arg, $serveur = '', $requeter = true) {
294 302
 	if (!preg_match('/^`?(\w+)`?\s+`?(\w+)`?\s+(.*?)\s*(DEFAULT .*?)?(NOT\s+NULL)?\s*(DEFAULT .*?)?$/i', $arg, $r)) {
295 303
 		spip_log("alter change: $arg  incompris", 'pg.' . _LOG_ERREUR);
@@ -416,6 +424,7 @@  discard block
 block discarded – undo
416 424
  * @param string /array $champs : liste de champs sur lesquels s'applique l'index
417 425
  * @param string $serveur : nom de la connexion sql utilisee
418 426
  * @param bool $requeter : true pour executer la requete ou false pour retourner le texte de la requete
427
+ * @param string $champs
419 428
  *
420 429
  * @return bool ou requete
421 430
  */
@@ -591,6 +600,9 @@  discard block
 block discarded – undo
591 600
 }
592 601
 
593 602
 // http://code.spip.net/@spip_pg_orderby
603
+/**
604
+ * @param string $order
605
+ */
594 606
 function spip_pg_orderby($order, $select) {
595 607
 	$res = array();
596 608
 	$arg = (is_array($order) ? $order : preg_split('/\s*,\s*/', $order));
@@ -765,6 +777,9 @@  discard block
 block discarded – undo
765 777
 }
766 778
 
767 779
 // http://code.spip.net/@calculer_pg_where
780
+/**
781
+ * @param string $v
782
+ */
768 783
 function calculer_pg_where($v) {
769 784
 	if (!is_array($v)) {
770 785
 		return spip_pg_frommysql($v);
@@ -790,6 +805,9 @@  discard block
 block discarded – undo
790 805
 
791 806
 
792 807
 // http://code.spip.net/@calculer_pg_expression
808
+/**
809
+ * @param string $expression
810
+ */
793 811
 function calculer_pg_expression($expression, $v, $join = 'AND') {
794 812
 	if (empty($v)) {
795 813
 		return '';
@@ -841,6 +859,9 @@  discard block
 block discarded – undo
841 859
 }
842 860
 
843 861
 // http://code.spip.net/@spip_pg_fetch
862
+/**
863
+ * @param resource $res
864
+ */
844 865
 function spip_pg_fetch($res, $t = '', $serveur = '', $requeter = true) {
845 866
 
846 867
 	if ($res) {
@@ -912,6 +933,10 @@  discard block
 block discarded – undo
912 933
 }
913 934
 
914 935
 // http://code.spip.net/@spip_pg_insert
936
+/**
937
+ * @param string $champs
938
+ * @param string $valeurs
939
+ */
915 940
 function spip_pg_insert($table, $champs, $valeurs, $desc = array(), $serveur = '', $requeter = true) {
916 941
 	$connexion = &$GLOBALS['connexions'][$serveur ? strtolower($serveur) : 0];
917 942
 	$prefixe = $connexion['prefixe'];
@@ -1148,6 +1173,9 @@  discard block
 block discarded – undo
1148 1173
 // Pas extensible pour le moment,
1149 1174
 
1150 1175
 // http://code.spip.net/@spip_pg_sequence
1176
+/**
1177
+ * @return string
1178
+ */
1151 1179
 function spip_pg_sequence($table, $raw = false) {
1152 1180
 
1153 1181
 	include_spip('base/serial');
@@ -1261,6 +1289,9 @@  discard block
 block discarded – undo
1261 1289
 }
1262 1290
 
1263 1291
 // http://code.spip.net/@spip_pg_error
1292
+/**
1293
+ * @param string $serveur
1294
+ */
1264 1295
 function spip_pg_error($query = '', $serveur, $requeter = true) {
1265 1296
 	$link = $GLOBALS['connexions'][$serveur ? strtolower($serveur) : 0]['link'];
1266 1297
 	$s = $link ? pg_last_error($link) : pg_last_error();
@@ -1311,7 +1342,7 @@  discard block
 block discarded – undo
1311 1342
  * @param bool $requeter
1312 1343
  *     true pour éxecuter la requête
1313 1344
  *     false pour retourner le texte de la requête.
1314
- * @return ressource
1345
+ * @return resource
1315 1346
  *     Ressource à utiliser avec sql_fetch()
1316 1347
  **/
1317 1348
 function spip_pg_showbase($match, $serveur = '', $requeter = true) {
Please login to merge, or discard this patch.
ecrire/req/sqlite_generique.php 1 patch
Doc Comments   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -996,7 +996,7 @@  discard block
 block discarded – undo
996 996
  * @param int $row_number Position. Déplacer le pointeur à cette ligne
997 997
  * @param string $serveur Nom de la connexion
998 998
  * @param bool $requeter Inutilisé
999
- * @return bool True si déplacement réussi, false sinon.
999
+ * @return boolean|null True si déplacement réussi, false sinon.
1000 1000
  **/
1001 1001
 function spip_sqlite_seek($r, $row_number, $serveur = '', $requeter = true) {
1002 1002
 	if ($r) {
@@ -1599,8 +1599,8 @@  discard block
 block discarded – undo
1599 1599
  * @param string|array $select Champs sélectionnés
1600 1600
  * @param string|array $from Tables sélectionnées
1601 1601
  * @param string|array $where Contraintes
1602
- * @param string|array $groupby Regroupements
1603
- * @param string|array $orderby Tris
1602
+ * @param string $groupby Regroupements
1603
+ * @param string $orderby Tris
1604 1604
  * @param string $limit Limites de résultats
1605 1605
  * @param string|array $having Contraintes posts sélections
1606 1606
  * @param string $serveur Nom de la connexion
@@ -1758,7 +1758,7 @@  discard block
 block discarded – undo
1758 1758
  * @param string $nom_table Nom de la table SQL
1759 1759
  * @param string $serveur Nom de la connexion
1760 1760
  * @param bool $requeter Exécuter la requête, sinon la retourner
1761
- * @return array|string
1761
+ * @return string
1762 1762
  *     - chaîne vide si pas de description obtenue
1763 1763
  *     - string Texte de la requête si demandé
1764 1764
  *     - array description de la table sinon
@@ -2694,7 +2694,7 @@  discard block
 block discarded – undo
2694 2694
  * stocke le resultat pour ne pas faire
2695 2695
  * de requetes showtable intempestives
2696 2696
  *
2697
- * @param  $table
2697
+ * @param  string $table
2698 2698
  * @param  $couples
2699 2699
  * @param string $desc
2700 2700
  * @param string $serveur
@@ -2886,7 +2886,7 @@  discard block
 block discarded – undo
2886 2886
 	 * Constructeur
2887 2887
 	 *
2888 2888
 	 * @param string $serveur
2889
-	 * @return bool
2889
+	 * @return false|null
2890 2890
 	 */
2891 2891
 	public function __construct($serveur = '') {
2892 2892
 		_sqlite_init();
Please login to merge, or discard this patch.
ecrire/xml/analyser_dtd.php 1 patch
Doc Comments   +24 added lines patch added patch discarded remove patch
@@ -167,6 +167,9 @@  discard block
 block discarded – undo
167 167
 }
168 168
 
169 169
 // http://code.spip.net/@analyser_dtd_comment
170
+/**
171
+ * @param string $dtd
172
+ */
170 173
 function analyser_dtd_comment($dtd, &$dtc, $grammaire) {
171 174
 	// ejecter les commentaires, surtout quand ils contiennent du code.
172 175
 	// Option /s car sur plusieurs lignes parfois
@@ -179,6 +182,9 @@  discard block
 block discarded – undo
179 182
 }
180 183
 
181 184
 // http://code.spip.net/@analyser_dtd_pi
185
+/**
186
+ * @param string $dtd
187
+ */
182 188
 function analyser_dtd_pi($dtd, &$dtc, $grammaire) {
183 189
 	if (!preg_match('/^<\?.*?>\s*(.*)$/s', $dtd, $m)) {
184 190
 		return -10;
@@ -188,6 +194,9 @@  discard block
 block discarded – undo
188 194
 }
189 195
 
190 196
 // http://code.spip.net/@analyser_dtd_lexeme
197
+/**
198
+ * @param string $dtd
199
+ */
191 200
 function analyser_dtd_lexeme($dtd, &$dtc, $grammaire) {
192 201
 
193 202
 	if (!preg_match(_REGEXP_ENTITY_DEF, $dtd, $m)) {
@@ -215,6 +224,9 @@  discard block
 block discarded – undo
215 224
 // ca ne depasse pas 3 ici.
216 225
 
217 226
 // http://code.spip.net/@analyser_dtd_data
227
+/**
228
+ * @param string $dtd
229
+ */
218 230
 function analyser_dtd_data($dtd, &$dtc, $grammaire) {
219 231
 
220 232
 	if (!preg_match(_REGEXP_INCLUDE_USE, $dtd, $m)) {
@@ -236,6 +248,9 @@  discard block
 block discarded – undo
236 248
 }
237 249
 
238 250
 // http://code.spip.net/@analyser_dtd_notation
251
+/**
252
+ * @param string $dtd
253
+ */
239 254
 function analyser_dtd_notation($dtd, &$dtc, $grammaire) {
240 255
 	if (!preg_match('/^<!NOTATION.*?>\s*(.*)$/s', $dtd, $m)) {
241 256
 		return -8;
@@ -246,6 +261,9 @@  discard block
 block discarded – undo
246 261
 }
247 262
 
248 263
 // http://code.spip.net/@analyser_dtd_entity
264
+/**
265
+ * @param string $dtd
266
+ */
249 267
 function analyser_dtd_entity($dtd, &$dtc, $grammaire) {
250 268
 	if (!preg_match(_REGEXP_ENTITY_DECL, $dtd, $m)) {
251 269
 		return -2;
@@ -303,6 +321,9 @@  discard block
 block discarded – undo
303 321
 // Fin du controle en finElement
304 322
 
305 323
 // http://code.spip.net/@analyser_dtd_element
324
+/**
325
+ * @param string $dtd
326
+ */
306 327
 function analyser_dtd_element($dtd, &$dtc, $grammaire) {
307 328
 	if (!preg_match('/^<!ELEMENT\s+([^>\s]+)([^>]*)>\s*(.*)$/s', $dtd, $m)) {
308 329
 		return -3;
@@ -351,6 +372,9 @@  discard block
 block discarded – undo
351 372
 
352 373
 
353 374
 // http://code.spip.net/@analyser_dtd_attlist
375
+/**
376
+ * @param string $dtd
377
+ */
354 378
 function analyser_dtd_attlist($dtd, &$dtc, $grammaire) {
355 379
 	if (!preg_match('/^<!ATTLIST\s+(\S+)\s+([^>]*)>\s*(.*)/s', $dtd, $m)) {
356 380
 		return -5;
Please login to merge, or discard this patch.