Completed
Push — spip-3.0 ( 5d8b58 )
by cam
53:01 queued 42:30
created
ecrire/inc/distant.php 1 patch
Doc Comments   +12 added lines patch added patch discarded remove patch
@@ -110,6 +110,9 @@  discard block
 block discarded – undo
110 110
 }
111 111
 
112 112
 // http://doc.spip.org/@prepare_donnees_post
113
+/**
114
+ * @param string $donnees
115
+ */
113 116
 function prepare_donnees_post($donnees, $boundary = '') {
114 117
 
115 118
 	// permettre a la fonction qui a demande le post de formater elle meme ses donnees
@@ -211,6 +214,9 @@  discard block
 block discarded – undo
211 214
 //   dans lequel on ecrit directement la page
212 215
 // * si c'est true/null ca correspond a une demande d'encodage/charset
213 216
 // http://doc.spip.org/@recuperer_page
217
+/**
218
+ * @param integer $taille_max
219
+ */
214 220
 function recuperer_page($url, $trans = false, $get_headers = false,
215 221
                         $taille_max = null, $datas = '', $boundary = '', $refuser_gz = false,
216 222
                         $date_verif = '', $uri_referer = ''){
@@ -655,6 +661,9 @@  discard block
 block discarded – undo
655 661
 // retourne le descripteur sur lequel lire la reponse
656 662
 //
657 663
 // http://doc.spip.org/@init_http
664
+/**
665
+ * @param string $method
666
+ */
658 667
 function init_http($method, $url, $refuse_gz = false, $referer = '', $datas = "", $vers = "HTTP/1.0", $date = ''){
659 668
 	$user = $via_proxy = $proxy_user = '';
660 669
 	$fopen = false;
@@ -699,6 +708,9 @@  discard block
 block discarded – undo
699 708
 }
700 709
 
701 710
 // http://doc.spip.org/@lance_requete
711
+/**
712
+ * @param string $noproxy
713
+ */
702 714
 function lance_requete($method, $scheme, $user, $host, $path, $port, $noproxy, $refuse_gz = false, $referer = '', $datas = "", $vers = "HTTP/1.0", $date = ''){
703 715
 
704 716
 	$proxy_user = '';
Please login to merge, or discard this patch.
ecrire/inc/drapeau_edition.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -19,6 +19,9 @@
 block discarded – undo
19 19
 }
20 20
 
21 21
 // http://doc.spip.org/@exec_meme_rubrique_args
22
+/**
23
+ * @param integer $id
24
+ */
22 25
 function exec_meme_rubrique_args($id, $type, $order)
23 26
 {
24 27
         if ((!autoriser('publierdans','rubrique',$id))
Please login to merge, or discard this patch.
ecrire/inc/editer.php 1 patch
Doc Comments   +17 added lines, -2 removed lines patch added patch discarded remove patch
@@ -57,6 +57,9 @@  discard block
 block discarded – undo
57 57
 }
58 58
 
59 59
 // http://doc.spip.org/@formulaires_editer_objet_verifier
60
+/**
61
+ * @param string $type
62
+ */
60 63
 function formulaires_editer_objet_verifier($type,$id='new', $oblis = array()){
61 64
 	$erreurs = array();
62 65
 	if (intval($id)) {
@@ -79,6 +82,9 @@  discard block
 block discarded – undo
79 82
 }
80 83
 
81 84
 // http://doc.spip.org/@formulaires_editer_objet_charger
85
+/**
86
+ * @param string $type
87
+ */
82 88
 function formulaires_editer_objet_charger($type, $id='new', $id_parent=0, $lier_trad=0, $retour='', $config_fonc='articles_edit_config', $row=array(), $hidden=''){
83 89
 	$table_objet = table_objet($type);
84 90
 	$table_objet_sql = table_objet_sql($type);
@@ -200,6 +206,9 @@  discard block
 block discarded – undo
200 206
 }
201 207
 
202 208
 // http://doc.spip.org/@editer_texte_recolle
209
+/**
210
+ * @param string $att_text
211
+ */
203 212
 function editer_texte_recolle($texte, $att_text)
204 213
 {
205 214
 	if ((strlen($texte)<29*1024)
@@ -222,8 +231,8 @@  discard block
 block discarded – undo
222 231
 /**
223 232
  * auto-renseigner le titre si il n'existe pas
224 233
  *
225
- * @param $champ_titre
226
- * @param $champs_contenu
234
+ * @param string $champ_titre
235
+ * @param string[] $champs_contenu
227 236
  * @param int $longueur
228 237
  */
229 238
 function titre_automatique($champ_titre,$champs_contenu,$longueur=null){
@@ -296,6 +305,9 @@  discard block
 block discarded – undo
296 305
 }
297 306
 
298 307
 // http://doc.spip.org/@controler_contenu
308
+/**
309
+ * @param string $id
310
+ */
299 311
 function controler_contenu($type, $id, $options=array(), $c=false, $serveur='') {
300 312
 	include_spip('inc/filtres');
301 313
 
@@ -366,6 +378,9 @@  discard block
 block discarded – undo
366 378
 // Controle la liste des md5 envoyes, supprime les inchanges,
367 379
 // signale les modifies depuis telle date
368 380
 // http://doc.spip.org/@controler_md5
381
+/**
382
+ * @param string $serveur
383
+ */
369 384
 function controler_md5(&$champs, $ctr, $type, $id, $serveur, $prefix = 'ctr_') {
370 385
 	$table_objet = table_objet($type);
371 386
 	$spip_table_objet = table_objet_sql($type);
Please login to merge, or discard this patch.
ecrire/inc/filtres.php 1 patch
Doc Comments   +52 added lines, -3 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
  * http://doc.spip.org/@chercher_filtre
38 38
  *
39 39
  * @param string $fonc
40
- * @param null $default
40
+ * @param string $default
41 41
  * @return string
42 42
  */
43 43
 function chercher_filtre($fonc, $default=NULL) {
@@ -117,6 +117,9 @@  discard block
 block discarded – undo
117 117
 // (numero non garanti pour l'espace public et en cas de mutualisation)
118 118
 // on est negatif si on est sur .svn, et positif si on utilise svn.revision
119 119
 // http://doc.spip.org/@version_svn_courante
120
+/**
121
+ * @param string $dir
122
+ */
120 123
 function version_svn_courante($dir) {
121 124
 	if (!$dir) $dir = '.';
122 125
 
@@ -169,6 +172,9 @@  discard block
 block discarded – undo
169 172
 
170 173
 // charge les fonctions graphiques et applique celle demandee
171 174
 // http://doc.spip.org/@filtrer
175
+/**
176
+ * @param string $filtre
177
+ */
172 178
 function filtrer($filtre) {
173 179
 	if (isset($GLOBALS['spip_matrice'][$filtre]) and is_string($f = $GLOBALS['spip_matrice'][$filtre])){
174 180
 		find_in_path($f,'', true);
@@ -363,12 +369,18 @@  discard block
 block discarded – undo
363 369
 // preserver des echappements de caracteres "bas" (par exemple [ ou ")
364 370
 // et au cas particulier de &amp; qui devient &amp;amp; dans les url
365 371
 // http://doc.spip.org/@corriger_entites_html
372
+/**
373
+ * @param string $texte
374
+ */
366 375
 function corriger_entites_html($texte) {
367 376
 	if (strpos($texte,'&amp;') === false) return $texte;
368 377
 	return preg_replace(',&amp;(#[0-9][0-9][0-9]+;|amp;),iS', '&\1', $texte);
369 378
 }
370 379
 // idem mais corriger aussi les &amp;eacute; en &eacute;
371 380
 // http://doc.spip.org/@corriger_toutes_entites_html
381
+/**
382
+ * @param string $texte
383
+ */
372 384
 function corriger_toutes_entites_html($texte) {
373 385
 	if (strpos($texte,'&amp;') === false) return $texte;
374 386
 	return preg_replace(',&amp;(#?[a-z0-9]+;),iS', '&\1', $texte);
@@ -434,6 +446,9 @@  discard block
 block discarded – undo
434 446
 
435 447
 // caracteres de controle - http://www.w3.org/TR/REC-xml/#charsets
436 448
 // http://doc.spip.org/@supprimer_caracteres_illegaux
449
+/**
450
+ * @param string $texte
451
+ */
437 452
 function supprimer_caracteres_illegaux($texte) {
438 453
 	static $from = "\x0\x1\x2\x3\x4\x5\x6\x7\x8\xB\xC\xE\xF\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\x1B\x1C\x1D\x1E\x1F";
439 454
 	static $to = null;
@@ -461,7 +476,7 @@  discard block
 block discarded – undo
461 476
  * http://doc.spip.org/@texte_backend
462 477
  *
463 478
  * @param $texte
464
- * @return mixed
479
+ * @return string
465 480
  */
466 481
 function texte_backend($texte) {
467 482
 
@@ -591,6 +606,9 @@  discard block
 block discarded – undo
591 606
 
592 607
 // Transformer les sauts de paragraphe en simples passages a la ligne
593 608
 // http://doc.spip.org/@PtoBR
609
+/**
610
+ * @param string $texte
611
+ */
594 612
 function PtoBR($texte){
595 613
 	$u = $GLOBALS['meta']['pcre_u'];
596 614
 	$texte = preg_replace("@</p>@iS", "\n", $texte);
@@ -649,6 +667,9 @@  discard block
 block discarded – undo
649 667
 
650 668
 // "127.4 ko" ou "3.1 Mo"
651 669
 // http://doc.spip.org/@taille_en_octets
670
+/**
671
+ * @param integer $taille
672
+ */
652 673
 function taille_en_octets ($taille) {
653 674
 	if ($taille < 1) return '';
654 675
 	if ($taille < 1024) {$taille = _T('taille_octets', array('taille' => $taille));}
@@ -753,6 +774,9 @@  discard block
 block discarded – undo
753 774
 
754 775
 // on normalise la date, si elle vient du contexte (public/parametrer.php), on force le jour
755 776
 // http://doc.spip.org/@normaliser_date
777
+/**
778
+ * @param string $date
779
+ */
756 780
 function normaliser_date($date, $forcer_jour = false) {
757 781
 	$date = vider_date($date);
758 782
 	if ($date) {
@@ -979,7 +1003,7 @@  discard block
 block discarded – undo
979 1003
  * http://doc.spip.org/@affdate_base
980 1004
  *
981 1005
  * @param $numdate
982
- * @param $vue
1006
+ * @param string $vue
983 1007
  * @param array $options
984 1008
  *   param : 'abbr' ou 'initiale' permet d'afficher les jours au format court ou initiale
985 1009
  *   annee_courante : permet de definir l'annee de reference pour l'affichage des dates courtes
@@ -1096,12 +1120,18 @@  discard block
 block discarded – undo
1096 1120
 }
1097 1121
 
1098 1122
 // http://doc.spip.org/@nom_jour
1123
+/**
1124
+ * @param string $numdate
1125
+ */
1099 1126
 function nom_jour($numdate, $forme = '') {
1100 1127
 	if(!($forme == 'abbr' OR $forme == 'initiale')) $forme = '';
1101 1128
 	return affdate_base($numdate, 'nom_jour', $forme);
1102 1129
 }
1103 1130
 
1104 1131
 // http://doc.spip.org/@jour
1132
+/**
1133
+ * @param string $numdate
1134
+ */
1105 1135
 function jour($numdate) {
1106 1136
 	return affdate_base($numdate, 'jour');
1107 1137
 }
@@ -1148,6 +1178,10 @@  discard block
 block discarded – undo
1148 1178
 }
1149 1179
 
1150 1180
 // http://doc.spip.org/@affdate_jourcourt
1181
+/**
1182
+ * @param string $numdate
1183
+ * @param string $annee_courante
1184
+ */
1151 1185
 function affdate_jourcourt($numdate, $annee_courante=null) {
1152 1186
 	return affdate_base($numdate, 'jourcourt', array('annee_courante'=>$annee_courante));
1153 1187
 }
@@ -1342,6 +1376,9 @@  discard block
 block discarded – undo
1342 1376
 // date_iso retourne la date au format "RFC 3339" / "ISO 8601"
1343 1377
 // voir http://www.php.net/manual/fr/ref.datetime.php#datetime.constants
1344 1378
 // http://doc.spip.org/@date_iso
1379
+/**
1380
+ * @param string $date_heure
1381
+ */
1345 1382
 function date_iso($date_heure) {
1346 1383
 	list($annee, $mois, $jour) = recup_date($date_heure);
1347 1384
 	list($heures, $minutes, $secondes) = recup_heure($date_heure);
@@ -1451,6 +1488,9 @@  discard block
 block discarded – undo
1451 1488
 // Extraire et transformer les blocs multi ; on indique la langue courante
1452 1489
 // pour ne pas mettre de span@lang=fr si on est deja en fr
1453 1490
 // http://doc.spip.org/@extraire_multi
1491
+/**
1492
+ * @param string $lang
1493
+ */
1454 1494
 function extraire_multi($letexte, $lang=null, $echappe_span=false) {
1455 1495
 	if (preg_match_all(_EXTRAIRE_MULTI, $letexte, $regs, PREG_SET_ORDER)) {
1456 1496
 		if (!$lang) $lang = $GLOBALS['spip_lang'];
@@ -1490,6 +1530,9 @@  discard block
 block discarded – undo
1490 1530
 
1491 1531
 // convertit le contenu d'une balise multi en un tableau
1492 1532
 // http://doc.spip.org/@extraire_trad
1533
+/**
1534
+ * @param string $bloc
1535
+ */
1493 1536
 function extraire_trads($bloc) {
1494 1537
 	$lang = '';
1495 1538
 // ce reg fait planter l'analyse multi s'il y a de l'{italique} dans le champ
@@ -1555,6 +1598,9 @@  discard block
 block discarded – undo
1555 1598
 // Exemple [(#COMPTEUR_BOUCLE|alterner{'bleu','vert','rouge'})]
1556 1599
 //
1557 1600
 // http://doc.spip.org/@alterner
1601
+/**
1602
+ * @param integer $i
1603
+ */
1558 1604
 function alterner($i) {
1559 1605
 	// recuperer les arguments (attention fonctions un peu space)
1560 1606
 	$num = func_num_args();
@@ -1897,6 +1943,9 @@  discard block
 block discarded – undo
1897 1943
 // l'URL donnee en argument, compatible avec les types_urls depuis [14447].
1898 1944
 // cf. tests/filtres/form_hidden.html
1899 1945
 // http://doc.spip.org/@form_hidden
1946
+/**
1947
+ * @param string $action
1948
+ */
1900 1949
 function form_hidden($action) {
1901 1950
 
1902 1951
 	$contexte = array();
Please login to merge, or discard this patch.
ecrire/inc/filtres_images_lib_mini.php 1 patch
Doc Comments   +8 added lines, -3 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
  *
75 75
  * @param bool|string $stat
76 76
  * 		true, false ou le statut déjà défini si traitements enchaînés.
77
- * @return bool
77
+ * @return false|null
78 78
  * 		true si il faut supprimer le fichier temporaire ; false sinon.
79 79
  */
80 80
 function statut_effacer_images_temporaires($stat){
@@ -472,7 +472,7 @@  discard block
 block discarded – undo
472 472
  * Crée un fichier_image temporaire .src ou vérifie que le fichier_image
473 473
  * définitif a bien été créé.
474 474
  *
475
- * @param ressource $img
475
+ * @param resource $img
476 476
  * 		Une ressource de type Image GD.
477 477
  * @param array $valeurs
478 478
  * 		Un tableau des informations (tailles, traitement, path...) accompagnant
@@ -943,6 +943,11 @@  discard block
 block discarded – undo
943 943
 }
944 944
 
945 945
 // http://doc.spip.org/@process_image_reduire
946
+/**
947
+ * @param boolean $force
948
+ * @param boolean $cherche_image
949
+ * @param string $process
950
+ */
946 951
 function process_image_reduire($fonction,$img,$taille,$taille_y,$force,$cherche_image,$process){
947 952
 	$image = false;
948 953
 	if (($process == 'AUTO') AND isset($GLOBALS['meta']['image_process']))
@@ -1070,7 +1075,7 @@  discard block
 block discarded – undo
1070 1075
 	}
1071 1076
 
1072 1077
 	/**
1073
-	 * @param array $gd_image_array
1078
+	 * @param ressource[] $gd_image_array
1074 1079
 	 * @return string
1075 1080
 	 */
1076 1081
 	public static function GD2ICOstring(&$gd_image_array) {
Please login to merge, or discard this patch.
ecrire/inc/flock.php 1 patch
Doc Comments   +9 added lines, -2 removed lines patch added patch discarded remove patch
@@ -26,6 +26,10 @@  discard block
 block discarded – undo
26 26
 
27 27
 $GLOBALS['liste_verrous'] = array();
28 28
 // http://doc.spip.org/@spip_fopen_lock
29
+/**
30
+ * @param string $mode
31
+ * @param integer $verrou
32
+ */
29 33
 function spip_fopen_lock($fichier,$mode,$verrou){
30 34
 	if (_SPIP_LOCK_MODE==1){
31 35
 		if ($fl = @fopen($fichier,$mode))
@@ -202,7 +206,7 @@  discard block
 block discarded – undo
202 206
  * Ecrire un contenu dans un fichier encapsule en php pour en empecher l'acces en l'absence
203 207
  * de htaccess
204 208
  * @param string $fichier
205
- * @param <type> $contenu
209
+ * @param string $contenu
206 210
  * @param <type> $ecrire_quand_meme
207 211
  * @param <type> $truncate 
208 212
  */
@@ -250,6 +254,9 @@  discard block
 block discarded – undo
250 254
 //
251 255
 
252 256
 // http://doc.spip.org/@jeune_fichier
257
+/**
258
+ * @param integer $n
259
+ */
253 260
 function jeune_fichier($fichier, $n)
254 261
 {
255 262
 	if (!file_exists($fichier)) return false;
@@ -292,7 +299,7 @@  discard block
 block discarded – undo
292 299
 /**
293 300
  * clearstatcache adapte a la version PHP
294 301
  * @param bool $clear_realpath_cache
295
- * @param null $filename
302
+ * @param string $filename
296 303
  */
297 304
 function spip_clearstatcache($clear_realpath_cache = false, $filename=null){
298 305
 	if (!defined('PHP_VERSION_ID') || PHP_VERSION_ID < 50300) {
Please login to merge, or discard this patch.
ecrire/inc/install.php 1 patch
Doc Comments   +11 added lines patch added patch discarded remove patch
@@ -252,6 +252,11 @@  discard block
 block discarded – undo
252 252
 }
253 253
 
254 254
 // http://doc.spip.org/@info_progression_etape
255
+/**
256
+ * @param integer $en_cours
257
+ * @param string $phase
258
+ * @param string $dir
259
+ */
255 260
 function info_progression_etape($en_cours,$phase,$dir, $erreur = false){
256 261
 	//$en_cours = _request('etape')?_request('etape'):"";
257 262
 	$liste = find_all_in_path($dir,$phase.'(([0-9])+|fin)[.]php$');
@@ -361,6 +366,9 @@  discard block
 block discarded – undo
361 366
 }
362 367
 
363 368
 // http://doc.spip.org/@install_connexion_form
369
+/**
370
+ * @param integer $etape
371
+ */
364 372
 function install_connexion_form($db, $login, $pass, $predef, $hidden, $etape, $jquery=true)
365 373
 {
366 374
 	$server_db = (is_string($predef[0])) ? $predef[0] : '';
@@ -521,6 +529,9 @@  discard block
 block discarded – undo
521 529
 	return array($checked, $bases);
522 530
 }
523 531
 
532
+/**
533
+ * @param string[] $hidden
534
+ */
524 535
 function install_propager($hidden)
525 536
 {
526 537
 	$res = '';
Please login to merge, or discard this patch.
ecrire/inc/invalideur.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -24,6 +24,9 @@  discard block
 block discarded – undo
24 24
 // Donne le nombre de fichiers dans un repertoire (plat, pour aller vite)
25 25
 // false si erreur
26 26
 // http://doc.spip.org/@nombre_de_fichiers_repertoire
27
+/**
28
+ * @param string $dir
29
+ */
27 30
 function nombre_de_fichiers_repertoire($dir,$nb_estim_taille = 20) {
28 31
 	$taille = 0; // mesurer la taille de N fichiers au hasard dans le repertoire
29 32
 	$nb = $nb_estim_taille;
@@ -249,6 +252,9 @@  discard block
 block discarded – undo
249 252
 
250 253
 // Calcul des pages : noter dans la base les liens d'invalidation
251 254
 // http://doc.spip.org/@maj_invalideurs
255
+/**
256
+ * @param string $fichier
257
+ */
252 258
 function maj_invalideurs ($fichier, &$page) { }
253 259
 
254 260
 // les invalideurs sont de la forme "objet/id_objet"
Please login to merge, or discard this patch.
ecrire/inc/lien.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -45,6 +45,9 @@  discard block
 block discarded – undo
45 45
 // Meme analyse mais pour eliminer les liens
46 46
 // et ne laisser que leur titre, a expliciter si ce n'est fait
47 47
 // http://doc.spip.org/@nettoyer_raccourcis_typo
48
+/**
49
+ * @param string|null $texte
50
+ */
48 51
 function nettoyer_raccourcis_typo($texte, $connect='')
49 52
 {
50 53
 
@@ -199,6 +202,9 @@  discard block
 block discarded – undo
199 202
 }
200 203
 
201 204
 // Retourne le champ textuel associe a une cle primaire, et sa langue
205
+/**
206
+ * @param string $connect
207
+ */
202 208
 function traiter_raccourci_titre($id, $type, $connect=NULL)
203 209
 {
204 210
 	$trouver_table = charger_fonction('trouver_table', 'base');
Please login to merge, or discard this patch.