@@ -18,6 +18,9 @@ discard block |
||
| 18 | 18 | // Use {page} in link_url als placeholder for the selected page number |
| 19 | 19 | // and/or {offset} for the 0-based data offset of the selected page. |
| 20 | 20 | |
| 21 | + /** |
|
| 22 | + * @param string $link_url |
|
| 23 | + */ |
|
| 21 | 24 | public function __construct($link_url, $min_pages_shown = 2, $max_pages_shown = 15) |
| 22 | 25 | { |
| 23 | 26 | global $tpl; |
@@ -31,6 +34,10 @@ discard block |
||
| 31 | 34 | } |
| 32 | 35 | |
| 33 | 36 | |
| 37 | + /** |
|
| 38 | + * @param double $current_page |
|
| 39 | + * @param double $total_pages |
|
| 40 | + */ |
|
| 34 | 41 | public function make_from_pagenr($current_page, $total_pages, $page_size = false) |
| 35 | 42 | { |
| 36 | 43 | global $tpl; |
@@ -94,6 +101,9 @@ discard block |
||
| 94 | 101 | } |
| 95 | 102 | |
| 96 | 103 | |
| 104 | + /** |
|
| 105 | + * @param boolean $page_size |
|
| 106 | + */ |
|
| 97 | 107 | private function pagelink($page, $page_size) |
| 98 | 108 | { |
| 99 | 109 | return mb_ereg_replace( |
@@ -19,6 +19,10 @@ discard block |
||
| 19 | 19 | |
| 20 | 20 | /* primaryKey may be an array |
| 21 | 21 | */ |
| 22 | + |
|
| 23 | + /** |
|
| 24 | + * @param string $sTable |
|
| 25 | + */ |
|
| 22 | 26 | public function __construct($sTable) |
| 23 | 27 | { |
| 24 | 28 | $this->pk = array(); |
@@ -26,6 +30,11 @@ discard block |
||
| 26 | 30 | $this->sTable = $sTable; |
| 27 | 31 | } |
| 28 | 32 | |
| 33 | + /** |
|
| 34 | + * @param string $sField |
|
| 35 | + * @param boolean $bNullable |
|
| 36 | + * @param integer $nInsertFunction |
|
| 37 | + */ |
|
| 29 | 38 | public function addPKInt($sField, $nDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 30 | 39 | { |
| 31 | 40 | $this->pk[$sField] = array( |
@@ -100,6 +109,11 @@ discard block |
||
| 100 | 109 | ); |
| 101 | 110 | } |
| 102 | 111 | |
| 112 | + /** |
|
| 113 | + * @param string $sField |
|
| 114 | + * @param boolean $bNullable |
|
| 115 | + * @param integer $nInsertFunction |
|
| 116 | + */ |
|
| 103 | 117 | public function addInt($sField, $nDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 104 | 118 | { |
| 105 | 119 | $this->fields[$sField] = array( |
@@ -112,6 +126,11 @@ discard block |
||
| 112 | 126 | ); |
| 113 | 127 | } |
| 114 | 128 | |
| 129 | + /** |
|
| 130 | + * @param string $sField |
|
| 131 | + * @param integer $nDefault |
|
| 132 | + * @param boolean $bNullable |
|
| 133 | + */ |
|
| 115 | 134 | public function addFloat($sField, $nDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 116 | 135 | { |
| 117 | 136 | $this->fields[$sField] = array( |
@@ -124,6 +143,11 @@ discard block |
||
| 124 | 143 | ); |
| 125 | 144 | } |
| 126 | 145 | |
| 146 | + /** |
|
| 147 | + * @param string $sField |
|
| 148 | + * @param integer $nDefault |
|
| 149 | + * @param boolean $bNullable |
|
| 150 | + */ |
|
| 127 | 151 | public function addDouble($sField, $nDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 128 | 152 | { |
| 129 | 153 | $this->fields[$sField] = array( |
@@ -136,6 +160,11 @@ discard block |
||
| 136 | 160 | ); |
| 137 | 161 | } |
| 138 | 162 | |
| 163 | + /** |
|
| 164 | + * @param string $sField |
|
| 165 | + * @param boolean $bNullable |
|
| 166 | + * @param integer $nInsertFunction |
|
| 167 | + */ |
|
| 139 | 168 | public function addString($sField, $sDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 140 | 169 | { |
| 141 | 170 | $this->fields[$sField] = array( |
@@ -148,6 +177,10 @@ discard block |
||
| 148 | 177 | ); |
| 149 | 178 | } |
| 150 | 179 | |
| 180 | + /** |
|
| 181 | + * @param string $sField |
|
| 182 | + * @param boolean $bNullable |
|
| 183 | + */ |
|
| 151 | 184 | public function addBoolean($sField, $bDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 152 | 185 | { |
| 153 | 186 | $this->fields[$sField] = array( |
@@ -160,6 +193,11 @@ discard block |
||
| 160 | 193 | ); |
| 161 | 194 | } |
| 162 | 195 | |
| 196 | + /** |
|
| 197 | + * @param string $sField |
|
| 198 | + * @param boolean $bNullable |
|
| 199 | + * @param integer $nInsertFunction |
|
| 200 | + */ |
|
| 163 | 201 | public function addDate($sField, $dDefault, $bNullable, $nInsertFunction = RE_INSERT_NOTHING) |
| 164 | 202 | { |
| 165 | 203 | $this->fields[$sField] = array( |
@@ -339,6 +377,9 @@ discard block |
||
| 339 | 377 | return join(' AND ', $fwhere); |
| 340 | 378 | } |
| 341 | 379 | |
| 380 | + /** |
|
| 381 | + * @param string $sField |
|
| 382 | + */ |
|
| 342 | 383 | public function getValue($sField) |
| 343 | 384 | { |
| 344 | 385 | if (isset($this->pk[$sField])) { |
@@ -353,6 +394,9 @@ discard block |
||
| 353 | 394 | return $this->fields[$sField]['default']; |
| 354 | 395 | } |
| 355 | 396 | |
| 397 | + /** |
|
| 398 | + * @param string $sField |
|
| 399 | + */ |
|
| 356 | 400 | public function getChanged($sField) |
| 357 | 401 | { |
| 358 | 402 | return $this->fields[$sField]['changed']; |
@@ -367,6 +411,9 @@ discard block |
||
| 367 | 411 | } |
| 368 | 412 | } |
| 369 | 413 | |
| 414 | + /** |
|
| 415 | + * @param string $sField |
|
| 416 | + */ |
|
| 370 | 417 | public function setValue($sField, $sValue) |
| 371 | 418 | { |
| 372 | 419 | if ($this->bLoaded == false || ($this->bAddNew == false && $this->bExist == false)) { |
@@ -556,6 +603,9 @@ discard block |
||
| 556 | 603 | return $sql; |
| 557 | 604 | } |
| 558 | 605 | |
| 606 | + /** |
|
| 607 | + * @param string $field |
|
| 608 | + */ |
|
| 559 | 609 | public function saveField($field) |
| 560 | 610 | { |
| 561 | 611 | if ($this->bLoaded == false || $this->bExist == false || $this->bAddNew == true) { |
@@ -13,6 +13,7 @@ |
||
| 13 | 13 | * |
| 14 | 14 | * @param int $items number of feeditems to parse from feed |
| 15 | 15 | * @param string $url url of the feed to parse |
| 16 | + * @param boolean $includetext |
|
| 16 | 17 | * |
| 17 | 18 | * @return string $item feeditems as HTML-string |
| 18 | 19 | */ |
@@ -159,6 +159,9 @@ discard block |
||
| 159 | 159 | } |
| 160 | 160 | |
| 161 | 161 | // str = long text |
| 162 | +/** |
|
| 163 | + * @param boolean $simple |
|
| 164 | + */ |
|
| 162 | 165 | function ftsearch_split(&$str, $simple) |
| 163 | 166 | { |
| 164 | 167 | global $ftsearch_ignores; |
@@ -488,6 +491,9 @@ discard block |
||
| 488 | 491 | sql("DELETE FROM `search_index_times` WHERE `object_type`='&1' AND `object_id`='&2'", $object_type, $object_id); |
| 489 | 492 | } |
| 490 | 493 | |
| 494 | +/** |
|
| 495 | + * @param integer $object_type |
|
| 496 | + */ |
|
| 491 | 497 | function ftsearch_set_entries($object_type, $object_id, $cache_id, &$text, $last_modified) |
| 492 | 498 | { |
| 493 | 499 | ftsearch_delete_entries($object_type, $object_id, $cache_id); |
@@ -569,6 +569,9 @@ |
||
| 569 | 569 | return $str; |
| 570 | 570 | } |
| 571 | 571 | |
| 572 | +/** |
|
| 573 | + * @return string |
|
| 574 | + */ |
|
| 572 | 575 | function changePlaceholder($str, $inverse = false) |
| 573 | 576 | { |
| 574 | 577 | static $translate = array( |
@@ -202,6 +202,10 @@ |
||
| 202 | 202 | } |
| 203 | 203 | |
| 204 | 204 | |
| 205 | +/** |
|
| 206 | + * @param string $interval |
|
| 207 | + * @param string $dateTimeEnd |
|
| 208 | + */ |
|
| 205 | 209 | function dateDiff($interval, $dateTimeBegin, $dateTimeEnd) |
| 206 | 210 | { |
| 207 | 211 | //Parse about any English textual datetime |
@@ -203,6 +203,9 @@ |
||
| 203 | 203 | return $str; |
| 204 | 204 | } |
| 205 | 205 | |
| 206 | +/** |
|
| 207 | + * @param string $str |
|
| 208 | + */ |
|
| 206 | 209 | function lf2crlf($str) |
| 207 | 210 | { |
| 208 | 211 | return str_replace("\r\r\n", "\r\n", str_replace("\n", "\r\n", $str)); |
@@ -107,6 +107,9 @@ discard block |
||
| 107 | 107 | return $rsResult; |
| 108 | 108 | } |
| 109 | 109 | |
| 110 | + /** |
|
| 111 | + * @param string $sql |
|
| 112 | + */ |
|
| 110 | 113 | public function strip_temptable($sql) |
| 111 | 114 | { |
| 112 | 115 | $start = stripos($sql, 'SELECT '); |
@@ -118,6 +121,9 @@ discard block |
||
| 118 | 121 | return substr($sql, $start); |
| 119 | 122 | } |
| 120 | 123 | |
| 124 | + /** |
|
| 125 | + * @param string $sql |
|
| 126 | + */ |
|
| 121 | 127 | public function strip_from($sql) |
| 122 | 128 | { |
| 123 | 129 | $start = stripos($sql, 'FROM '); |
@@ -129,6 +135,9 @@ discard block |
||
| 129 | 135 | return 'SELECT * ' . substr($sql, $start); |
| 130 | 136 | } |
| 131 | 137 | |
| 138 | + /** |
|
| 139 | + * @param string $sql |
|
| 140 | + */ |
|
| 132 | 141 | public function insert_nocache($sql) |
| 133 | 142 | { |
| 134 | 143 | if (strtoupper(substr($sql, 0, 7)) == 'SELECT ') { |
@@ -283,7 +283,7 @@ discard block |
||
| 283 | 283 | /** Removes entry from the archive. |
| 284 | 284 | * please be very carefull with this function, there is no undo after you save the archive |
| 285 | 285 | * |
| 286 | - * @return bool true on success or false on failure |
|
| 286 | + * @return boolean|null true on success or false on failure |
|
| 287 | 287 | * |
| 288 | 288 | * @param int $idx |
| 289 | 289 | */ |
@@ -334,6 +334,10 @@ discard block |
||
| 334 | 334 | return $idx >= 0 and $idx < $this->cnt; |
| 335 | 335 | } |
| 336 | 336 | |
| 337 | + /** |
|
| 338 | + * @param string $name |
|
| 339 | + * @param string $data |
|
| 340 | + */ |
|
| 337 | 341 | public function _write($name, $data) |
| 338 | 342 | { |
| 339 | 343 | $fp = fopen($name, "w"); |