@@ -470,6 +470,7 @@ discard block |
||
470 | 470 | * |
471 | 471 | * Get link info |
472 | 472 | * @param int link id |
473 | + * @param integer $id |
|
473 | 474 | * @return array link info |
474 | 475 | * |
475 | 476 | **/ |
@@ -855,7 +856,7 @@ discard block |
||
855 | 856 | } |
856 | 857 | |
857 | 858 | /** |
858 | - * @param $categoryId |
|
859 | + * @param integer $categoryId |
|
859 | 860 | * @param $courseId |
860 | 861 | * @param $sessionId |
861 | 862 | * @param bool $withBaseContent |
@@ -902,8 +903,8 @@ discard block |
||
902 | 903 | * @author Julio Montoya |
903 | 904 | * |
904 | 905 | * @param $catid |
905 | - * @param $courseId |
|
906 | - * @param $session_id |
|
906 | + * @param integer $courseId |
|
907 | + * @param integer $session_id |
|
907 | 908 | * @return string |
908 | 909 | */ |
909 | 910 | public static function showLinksPerCategory($catid, $courseId, $session_id) |
@@ -1107,6 +1108,8 @@ discard block |
||
1107 | 1108 | /** |
1108 | 1109 | * Displays the edit, delete and move icons |
1109 | 1110 | * @param int Category ID |
1111 | + * @param integer $currentCategory |
|
1112 | + * @param integer $countCategories |
|
1110 | 1113 | * @return string |
1111 | 1114 | * |
1112 | 1115 | * @author Patrick Cool <[email protected]>, Ghent University |
@@ -1247,6 +1250,7 @@ discard block |
||
1247 | 1250 | /** |
1248 | 1251 | * CSV file import functions |
1249 | 1252 | * @author René Haentjens , Ghent University |
1253 | + * @param string $catname |
|
1250 | 1254 | */ |
1251 | 1255 | public static function get_cat($catname) |
1252 | 1256 | { |
@@ -1281,6 +1285,11 @@ discard block |
||
1281 | 1285 | /** |
1282 | 1286 | * CSV file import functions |
1283 | 1287 | * @author René Haentjens , Ghent University |
1288 | + * @param string $url |
|
1289 | + * @param string $title |
|
1290 | + * @param string $description |
|
1291 | + * @param string $on_homepage |
|
1292 | + * @param string $hidden |
|
1284 | 1293 | */ |
1285 | 1294 | public static function put_link($url, $cat, $title, $description, $on_homepage, $hidden) |
1286 | 1295 | { |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | * @param string $course Course code |
90 | 90 | * @param integer $lp_id |
91 | 91 | * @param integer $user_id |
92 | - * @return mixed True on success, false on error |
|
92 | + * @return boolean True on success, false on error |
|
93 | 93 | */ |
94 | 94 | public function __construct($course, $lp_id, $user_id) |
95 | 95 | { |
@@ -492,7 +492,7 @@ discard block |
||
492 | 492 | * @param int $max_time_allowed |
493 | 493 | * @param int $userId |
494 | 494 | * |
495 | - * @return int |
|
495 | + * @return false|string |
|
496 | 496 | */ |
497 | 497 | public function add_item( |
498 | 498 | $parent, |
@@ -1042,7 +1042,7 @@ discard block |
||
1042 | 1042 | * @param array $courseInfo |
1043 | 1043 | * @param integer Learnpath ID |
1044 | 1044 | * @param string Whether to delete data or keep it (default: 'keep', others: 'remove') |
1045 | - * @return boolean True on success, false on failure (might change that to return number of elements deleted) |
|
1045 | + * @return false|null True on success, false on failure (might change that to return number of elements deleted) |
|
1046 | 1046 | */ |
1047 | 1047 | public function delete($courseInfo = null, $id = null, $delete = 'keep') |
1048 | 1048 | { |
@@ -1182,7 +1182,7 @@ discard block |
||
1182 | 1182 | * @param integer $id Elem ID (0 if first) |
1183 | 1183 | * @param integer $remove Whether to remove the resource/data from the |
1184 | 1184 | * system or leave it (default: 'keep', others 'remove') |
1185 | - * @return integer Number of elements moved |
|
1185 | + * @return false|null Number of elements moved |
|
1186 | 1186 | * @todo implement resource removal |
1187 | 1187 | */ |
1188 | 1188 | public function delete_item($id, $remove = 'keep') |
@@ -1264,7 +1264,7 @@ discard block |
||
1264 | 1264 | * @param array $audio The array resulting of the $_FILES[mp3] element |
1265 | 1265 | * @param int $max_time_allowed |
1266 | 1266 | * @param string $url |
1267 | - * @return boolean True on success, false on error |
|
1267 | + * @return false|null True on success, false on error |
|
1268 | 1268 | */ |
1269 | 1269 | public function edit_item( |
1270 | 1270 | $id, |
@@ -1783,7 +1783,7 @@ discard block |
||
1783 | 1783 | |
1784 | 1784 | /** |
1785 | 1785 | * Gets the first element URL. |
1786 | - * @return string URL to load into the viewer |
|
1786 | + * @return false|null URL to load into the viewer |
|
1787 | 1787 | */ |
1788 | 1788 | public function first() |
1789 | 1789 | { |
@@ -2283,8 +2283,9 @@ discard block |
||
2283 | 2283 | } |
2284 | 2284 | |
2285 | 2285 | /** |
2286 | - * @param int $lpId |
|
2287 | 2286 | * @param array $courseInfo |
2287 | + * @param integer $student_id |
|
2288 | + * @param integer $sessionId |
|
2288 | 2289 | * @return bool |
2289 | 2290 | * |
2290 | 2291 | */ |
@@ -2316,6 +2317,7 @@ discard block |
||
2316 | 2317 | * @param int $student_id |
2317 | 2318 | * @param string Course code (optional) |
2318 | 2319 | * @param int $sessionId |
2320 | + * @param string $courseCode |
|
2319 | 2321 | * @return bool |
2320 | 2322 | */ |
2321 | 2323 | public static function is_lp_visible_for_student( |
@@ -2607,7 +2609,7 @@ discard block |
||
2607 | 2609 | |
2608 | 2610 | /** |
2609 | 2611 | * Gets the learnpath session id |
2610 | - * @return string Learnpath theme |
|
2612 | + * @return integer Learnpath theme |
|
2611 | 2613 | */ |
2612 | 2614 | public function get_lp_session_id() |
2613 | 2615 | { |
@@ -2640,7 +2642,7 @@ discard block |
||
2640 | 2642 | /** |
2641 | 2643 | * @param string $size |
2642 | 2644 | * @param string $path_type |
2643 | - * @return bool|string |
|
2645 | + * @return string|false |
|
2644 | 2646 | */ |
2645 | 2647 | public function get_preview_image_path($size = null, $path_type = 'web') |
2646 | 2648 | { |
@@ -2786,6 +2788,8 @@ discard block |
||
2786 | 2788 | * Returns the XML DOM document's node |
2787 | 2789 | * @param resource Reference to a list of objects to search for the given ITEM_* |
2788 | 2790 | * @param string The identifier to look for |
2791 | + * @param DOMNodeList $children |
|
2792 | + * @param string $id |
|
2789 | 2793 | * @return mixed The reference to the element found with that identifier. False if not found |
2790 | 2794 | */ |
2791 | 2795 | public function get_scorm_xml_node(& $children, $id) |
@@ -2971,7 +2975,7 @@ discard block |
||
2971 | 2975 | /** |
2972 | 2976 | * Generate and return the table of contents for this learnpath. The (flat) table returned can be |
2973 | 2977 | * used by get_html_toc() to be ready to display |
2974 | - * @return array TOC as a table with 4 elements per row: title, link, status and level |
|
2978 | + * @return boolean TOC as a table with 4 elements per row: title, link, status and level |
|
2975 | 2979 | */ |
2976 | 2980 | public function get_toc() |
2977 | 2981 | { |
@@ -3107,7 +3111,7 @@ discard block |
||
3107 | 3111 | } |
3108 | 3112 | |
3109 | 3113 | /** |
3110 | - * @return array |
|
3114 | + * @return string[] |
|
3111 | 3115 | */ |
3112 | 3116 | public static function getChapterTypes() |
3113 | 3117 | { |
@@ -3996,7 +4000,7 @@ discard block |
||
3996 | 4000 | * Open a resource = initialise all local variables relative to this resource. Depending on the child |
3997 | 4001 | * class, this might be redefined to allow several behaviours depending on the document type. |
3998 | 4002 | * @param integer Resource ID |
3999 | - * @return boolean True on success, false otherwise |
|
4003 | + * @return boolean|null True on success, false otherwise |
|
4000 | 4004 | */ |
4001 | 4005 | public function open($id) |
4002 | 4006 | { |
@@ -4125,7 +4129,7 @@ discard block |
||
4125 | 4129 | * Can be used as abstract |
4126 | 4130 | * @param integer $lp_id Learnpath id |
4127 | 4131 | * @param string $set_visibility New visibility (v/i - visible/invisible) |
4128 | - * @return bool |
|
4132 | + * @return null|false |
|
4129 | 4133 | */ |
4130 | 4134 | public static function toggle_publish($lp_id, $set_visibility = 'v') |
4131 | 4135 | { |
@@ -4212,7 +4216,7 @@ discard block |
||
4212 | 4216 | * Make sure the results are saved with anoter method. This method should probably be |
4213 | 4217 | * redefined in children classes. |
4214 | 4218 | * To use a similar method statically, use the create_new_attempt() method |
4215 | - * @return string URL to load in the viewer |
|
4219 | + * @return boolean URL to load in the viewer |
|
4216 | 4220 | */ |
4217 | 4221 | public function restart() |
4218 | 4222 | { |
@@ -4288,6 +4292,7 @@ discard block |
||
4288 | 4292 | * Saves the given item |
4289 | 4293 | * @param integer $item_id. Optional (will take from $_REQUEST if null) |
4290 | 4294 | * @param boolean $from_outside Save from url params (true) or from current attributes (false). Optional. Defaults to true |
4295 | + * @param integer $item_id |
|
4291 | 4296 | * @return boolean |
4292 | 4297 | */ |
4293 | 4298 | public function save_item($item_id = null, $from_outside = true) |
@@ -4787,7 +4792,7 @@ discard block |
||
4787 | 4792 | |
4788 | 4793 | /** |
4789 | 4794 | * Sets use_max_score |
4790 | - * @param string $use_max_score Optional string giving the new location of this learnpath |
|
4795 | + * @param integer $use_max_score Optional string giving the new location of this learnpath |
|
4791 | 4796 | * @return boolean True on success / False on error |
4792 | 4797 | */ |
4793 | 4798 | public function set_use_max_score($use_max_score = 1) |
@@ -5190,6 +5195,7 @@ discard block |
||
5190 | 5195 | * Register the attempt mode into db thanks to flags prevent_reinit and seriousgame_mode flags |
5191 | 5196 | * |
5192 | 5197 | * @param string 'seriousgame', 'single' or 'multiple' |
5198 | + * @param string $mode |
|
5193 | 5199 | * @return boolean |
5194 | 5200 | * @author ndiechburg <[email protected]> |
5195 | 5201 | **/ |
@@ -5232,7 +5238,7 @@ discard block |
||
5232 | 5238 | /** |
5233 | 5239 | * Switch between multiple attempt, single attempt or serious_game mode (only for scorm) |
5234 | 5240 | * |
5235 | - * @return boolean |
|
5241 | + * @return boolean|null |
|
5236 | 5242 | * @author ndiechburg <[email protected]> |
5237 | 5243 | **/ |
5238 | 5244 | public function switch_attempt_mode() |
@@ -5423,7 +5429,6 @@ discard block |
||
5423 | 5429 | /** |
5424 | 5430 | * Function that creates a html list of learning path items so that we can add audio files to them |
5425 | 5431 | * @author Kevin Van Den Haute |
5426 | - * @param int $lp_id |
|
5427 | 5432 | * @return string |
5428 | 5433 | */ |
5429 | 5434 | public function overview() |
@@ -6444,7 +6449,7 @@ discard block |
||
6444 | 6449 | /** |
6445 | 6450 | * Function that displays a list with al the resources that |
6446 | 6451 | * could be added to the learning path |
6447 | - * @return string |
|
6452 | + * @return boolean |
|
6448 | 6453 | */ |
6449 | 6454 | public function display_resources() |
6450 | 6455 | { |
@@ -10053,7 +10058,7 @@ discard block |
||
10053 | 10058 | |
10054 | 10059 | /** |
10055 | 10060 | * @param int $lp_id |
10056 | - * @return bool |
|
10061 | + * @return false|null |
|
10057 | 10062 | */ |
10058 | 10063 | public function scorm_export_to_pdf($lp_id) |
10059 | 10064 | { |
@@ -10584,7 +10589,7 @@ discard block |
||
10584 | 10589 | |
10585 | 10590 | /** |
10586 | 10591 | * @param int $itemId |
10587 | - * @return learnpathItem|false |
|
10592 | + * @return string |
|
10588 | 10593 | */ |
10589 | 10594 | public function getItem($itemId) |
10590 | 10595 | { |
@@ -10634,7 +10639,6 @@ discard block |
||
10634 | 10639 | /** |
10635 | 10640 | * Set whether this is a learning path with the possibility to subscribe |
10636 | 10641 | * users or not |
10637 | - * @param int $subscribeUsers (0 = false, 1 = true) |
|
10638 | 10642 | */ |
10639 | 10643 | public function setSubscribeUsers($value) |
10640 | 10644 | { |
@@ -10759,7 +10763,7 @@ discard block |
||
10759 | 10763 | |
10760 | 10764 | /** |
10761 | 10765 | * Get the item of exercise type (evaluation type) |
10762 | - * @return array The final evaluation. Otherwise return false |
|
10766 | + * @return integer The final evaluation. Otherwise return false |
|
10763 | 10767 | */ |
10764 | 10768 | public function getFinalEvaluationItem() |
10765 | 10769 | { |
@@ -10980,7 +10984,7 @@ discard block |
||
10980 | 10984 | /** |
10981 | 10985 | * Create a forum for this learning path |
10982 | 10986 | * @param type $forumCategoryId |
10983 | - * @return int The forum ID if was created. Otherwise return false |
|
10987 | + * @return false|string The forum ID if was created. Otherwise return false |
|
10984 | 10988 | */ |
10985 | 10989 | public function createForum($forumCategoryId) |
10986 | 10990 | { |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | } |
34 | 34 | |
35 | 35 | /** |
36 | - * @return array |
|
36 | + * @return string[] |
|
37 | 37 | */ |
38 | 38 | public static function toolList() |
39 | 39 | { |
@@ -293,7 +293,6 @@ discard block |
||
293 | 293 | * 'page_nr' = The page to display |
294 | 294 | * 'hide_navigation' = true to hide the navigation |
295 | 295 | * @param array $query_vars Additional variables to add in the query-string |
296 | - * @param array $form actions Additional variables to add in the query-string |
|
297 | 296 | * @param mixed An array with bool values to know which columns show. |
298 | 297 | * i.e: $visibility_options= array(true, false) we will only show the first column |
299 | 298 | * Can be also only a bool value. TRUE: show all columns, FALSE: show nothing |
@@ -334,7 +333,6 @@ discard block |
||
334 | 333 | * 'page_nr' = The page to display |
335 | 334 | * 'hide_navigation' = true to hide the navigation |
336 | 335 | * @param array $query_vars Additional variables to add in the query-string |
337 | - * @param array $form actions Additional variables to add in the query-string |
|
338 | 336 | * @param mixed An array with bool values to know which columns show. i.e: |
339 | 337 | * $visibility_options= array(true, false) we will only show the first column |
340 | 338 | * Can be also only a bool value. TRUE: show all columns, FALSE: show nothing |
@@ -391,10 +389,11 @@ discard block |
||
391 | 389 | * 'per_page' = number of items to show per page |
392 | 390 | * 'page_nr' = The page to display |
393 | 391 | * @param array $query_vars Additional variables to add in the query-string |
394 | - * @param array $column_show Array of binaries 1= show columns 0. hide a column |
|
392 | + * @param integer[] $column_show Array of binaries 1= show columns 0. hide a column |
|
395 | 393 | * @param array $column_order An array of integers that let us decide how the columns are going to be sort. |
396 | 394 | * i.e: $column_order=array('1''4','3','4'); The 2nd column will be order like the 4th column |
397 | 395 | * @param array $form_actions Set optional forms actions |
396 | + * @param string $table_name |
|
398 | 397 | * |
399 | 398 | * @author Julio Montoya |
400 | 399 | */ |
@@ -449,7 +448,7 @@ discard block |
||
449 | 448 | * |
450 | 449 | * @deprecated use Display::addFlash with Display::return_message($message, 'normal'); |
451 | 450 | * |
452 | - * @return void |
|
451 | + * @return string|null |
|
453 | 452 | */ |
454 | 453 | public static function display_normal_message($message, $filter = true, $returnValue = false) |
455 | 454 | { |
@@ -481,7 +480,7 @@ discard block |
||
481 | 480 | * Displays an confirmation message. Use this if something has been done successfully |
482 | 481 | * @param bool Filter (true) or not (false) |
483 | 482 | * @deprecated use Display::addFlash with Display::return_message |
484 | - * @return void |
|
483 | + * @return string|null |
|
485 | 484 | */ |
486 | 485 | public static function display_confirmation_message ($message, $filter = true, $returnValue = false) |
487 | 486 | { |
@@ -500,7 +499,7 @@ discard block |
||
500 | 499 | * @param bool Filter (true) or not (false) |
501 | 500 | * @deprecated use Display::addFlash with Display::return_message |
502 | 501 | * |
503 | - * @return void |
|
502 | + * @return string|null |
|
504 | 503 | */ |
505 | 504 | public static function display_error_message ($message, $filter = true, $returnValue = false) |
506 | 505 | { |
@@ -681,6 +680,7 @@ discard block |
||
681 | 680 | * @param string The alt text (probably a language variable) |
682 | 681 | * @param array additional attributes (for instance height, width, onclick, ...) |
683 | 682 | * @param integer The wanted width of the icon (to be looked for in the corresponding img/icons/ folder) |
683 | + * @param string $image |
|
684 | 684 | * @return void |
685 | 685 | */ |
686 | 686 | public static function display_icon( |
@@ -917,6 +917,7 @@ discard block |
||
917 | 917 | /** |
918 | 918 | * Displays an HTML input tag |
919 | 919 | * |
920 | + * @param string $type |
|
920 | 921 | */ |
921 | 922 | public static function input($type, $name, $value, $attributes = array()) |
922 | 923 | { |
@@ -933,8 +934,8 @@ discard block |
||
933 | 934 | } |
934 | 935 | |
935 | 936 | /** |
936 | - * @param $name |
|
937 | - * @param $value |
|
937 | + * @param string $name |
|
938 | + * @param string $value |
|
938 | 939 | * @param array $attributes |
939 | 940 | * @return string |
940 | 941 | */ |
@@ -949,6 +950,7 @@ discard block |
||
949 | 950 | /** |
950 | 951 | * Displays an HTML select tag |
951 | 952 | * |
953 | + * @param string $blank_item_text |
|
952 | 954 | */ |
953 | 955 | public static function select( |
954 | 956 | $name, |
@@ -1015,8 +1017,8 @@ discard block |
||
1015 | 1017 | $( "#tabs" ).tabs(); |
1016 | 1018 | }); |
1017 | 1019 | </script> |
1018 | - * @param array $headers list of the tab titles |
|
1019 | - * @param array $items |
|
1020 | + * @param string[] $headers list of the tab titles |
|
1021 | + * @param string[] $items |
|
1020 | 1022 | * @param string $id id of the container of the tab in the example "tabs" |
1021 | 1023 | * @param array $attributes for the ul |
1022 | 1024 | * @param array $ul_attributes |
@@ -1070,7 +1072,7 @@ discard block |
||
1070 | 1072 | |
1071 | 1073 | /** |
1072 | 1074 | * @param $headers |
1073 | - * @param null $selected |
|
1075 | + * @param integer $selected |
|
1074 | 1076 | * |
1075 | 1077 | * @return string |
1076 | 1078 | */ |
@@ -1108,6 +1110,7 @@ discard block |
||
1108 | 1110 | * As you can see both function use the same "my_grid_name" this is very important otherwise nothing will work |
1109 | 1111 | * |
1110 | 1112 | * @param string the div id, this value must be the same with the first parameter of Display::grid_js() |
1113 | + * @param string $div_id |
|
1111 | 1114 | * @return string html |
1112 | 1115 | * |
1113 | 1116 | */ |
@@ -1668,6 +1671,8 @@ discard block |
||
1668 | 1671 | * @param string url that will be added (for jquery see hot_courses.tpl) |
1669 | 1672 | * @param string point info array see function CourseManager::get_course_ranking() |
1670 | 1673 | * @param bool add a div wrapper |
1674 | + * @param string $id |
|
1675 | + * @param string $url |
|
1671 | 1676 | * @todo use templates |
1672 | 1677 | **/ |
1673 | 1678 | public static function return_rating_system($id, $url, $point_info = array(), $add_div_wrapper = true) |
@@ -1758,6 +1763,9 @@ discard block |
||
1758 | 1763 | return '<'.$size.'>'.Security::remove_XSS($title).'</'.$size.'>'; |
1759 | 1764 | } |
1760 | 1765 | |
1766 | + /** |
|
1767 | + * @param string $title |
|
1768 | + */ |
|
1761 | 1769 | public static function page_subheader2($title, $second_title = null) |
1762 | 1770 | { |
1763 | 1771 | return self::page_header($title, $second_title, 'h4'); |
@@ -2005,6 +2013,7 @@ discard block |
||
2005 | 2013 | |
2006 | 2014 | /** |
2007 | 2015 | * @todo use twig |
2016 | + * @param string $title |
|
2008 | 2017 | */ |
2009 | 2018 | public static function groupButtonWithDropDown($title, $elements) |
2010 | 2019 | { |
@@ -2378,9 +2387,9 @@ discard block |
||
2378 | 2387 | |
2379 | 2388 | /** |
2380 | 2389 | * @param int $id |
2381 | - * @param array $content |
|
2390 | + * @param string[] $content |
|
2382 | 2391 | * @param int $col |
2383 | - * @param bool|true $right |
|
2392 | + * @param boolean $right |
|
2384 | 2393 | * @return string |
2385 | 2394 | */ |
2386 | 2395 | public static function toolbarAction($id, $content = array(), $col = 2, $right = true) |
@@ -2464,10 +2473,10 @@ discard block |
||
2464 | 2473 | /** |
2465 | 2474 | * @param string $title |
2466 | 2475 | * @param string $content |
2467 | - * @param null $id |
|
2476 | + * @param string $id |
|
2468 | 2477 | * @param array $params |
2469 | - * @param null $idAccordion |
|
2470 | - * @param null $idCollapse |
|
2478 | + * @param string $idAccordion |
|
2479 | + * @param string $idCollapse |
|
2471 | 2480 | * @param bool|true $open |
2472 | 2481 | * @param bool|false $fullClickable |
2473 | 2482 | * @return null|string |