diff options
author | Andreas Gohr <andi@splitbrain.org> | 2014-12-09 20:11:00 +0100 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2014-12-09 20:11:00 +0100 |
commit | 61a4313f55c7e83e0b78c9c6a8eb2efb13ff0512 (patch) | |
tree | c7269ea61f5d4230a6f916dbabee4ce412e0a9fb /inc/html.php | |
parent | 9a0ca2cfd8ac42895af3be2efbd2cab7e6d33578 (diff) | |
parent | 8702de7f7e170bddfdb622c393c3cac3446fd1c5 (diff) | |
download | rpg-61a4313f55c7e83e0b78c9c6a8eb2efb13ff0512.tar.gz rpg-61a4313f55c7e83e0b78c9c6a8eb2efb13ff0512.tar.bz2 |
Merge pull request #945 from splitbrain/scrutinizerissues
Scrutinizer issues and IXR library updates
Diffstat (limited to 'inc/html.php')
-rw-r--r-- | inc/html.php | 74 |
1 files changed, 68 insertions, 6 deletions
diff --git a/inc/html.php b/inc/html.php index 495bdf919..711cd8db6 100644 --- a/inc/html.php +++ b/inc/html.php @@ -83,6 +83,10 @@ function html_denied() { * inserts section edit buttons if wanted or removes the markers * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param string $text + * @param bool $show show section edit buttons? + * @return string */ function html_secedit($text,$show=true){ global $INFO; @@ -101,8 +105,11 @@ function html_secedit($text,$show=true){ * prepares section edit button data for event triggering * used as a callback in html_secedit * - * @triggers HTML_SECEDIT_BUTTON * @author Andreas Gohr <andi@splitbrain.org> + * + * @param array $matches matches with regexp + * @return string + * @triggers HTML_SECEDIT_BUTTON */ function html_secedit_button($matches){ $data = array('secid' => $matches[1], @@ -121,6 +128,9 @@ function html_secedit_button($matches){ * used as default action form HTML_SECEDIT_BUTTON * * @author Adrian Lang <lang@cosmocode.de> + * + * @param array $data name, section id and target + * @return string html */ function html_secedit_get_button($data) { global $ID; @@ -147,6 +157,8 @@ function html_secedit_get_button($data) { * Just the back to top button (in its own form) * * @author Andreas Gohr <andi@splitbrain.org> + * + * @return string html */ function html_topbtn(){ global $lang; @@ -161,6 +173,15 @@ function html_topbtn(){ * If tooltip exists, the access key tooltip is replaced. * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param string $name + * @param string $id + * @param string $akey access key + * @param string[] $params key-value pairs added as hidden inputs + * @param string $method + * @param string $tooltip + * @param bool|string $label label text, false: lookup btn_$name in localization + * @return string */ function html_btn($name,$id,$akey,$params,$method='get',$tooltip='',$label=false){ global $conf; @@ -213,9 +234,11 @@ function html_btn($name,$id,$akey,$params,$method='get',$tooltip='',$label=false } /** - * show a wiki page + * Show a wiki page * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param null|string $txt wiki text or null for showing $ID */ function html_show($txt=null){ global $ID; @@ -282,6 +305,10 @@ function html_draft(){ * * @author Andreas Gohr <andi@splitbrain.org> * @author Harry Fuecks <hfuecks@gmail.com> + * + * @param string $html + * @param array|string $phrases + * @return string html */ function html_hilight($html,$phrases){ $phrases = (array) $phrases; @@ -300,6 +327,9 @@ function html_hilight($html,$phrases){ * Callback used by html_hilight() * * @author Harry Fuecks <hfuecks@gmail.com> + * + * @param array $m matches + * @return string html */ function html_hilight_callback($m) { $hlight = unslash($m[0]); @@ -425,6 +455,9 @@ function html_locked(){ * @author Andreas Gohr <andi@splitbrain.org> * @author Ben Coburn <btcoburn@silicodon.net> * @author Kate Arzamastseva <pshns@ukr.net> + * + * @param int $first skip the first n changelog lines + * @param bool|string $media_id id of media, or false for current page */ function html_revisions($first=0, $media_id = false){ global $ID; @@ -646,6 +679,9 @@ function html_revisions($first=0, $media_id = false){ * @author Matthias Grimm <matthiasgrimm@users.sourceforge.net> * @author Ben Coburn <btcoburn@silicodon.net> * @author Kate Arzamastseva <pshns@ukr.net> + * + * @param int $first + * @param string $show_changes */ function html_recent($first=0, $show_changes='both'){ global $conf; @@ -833,6 +869,8 @@ function html_recent($first=0, $show_changes='both'){ * Display page index * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param string $ns */ function html_index($ns){ global $conf; @@ -861,6 +899,9 @@ function html_index($ns){ * User function for html_buildlist() * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param array $item + * @return string */ function html_list_index($item){ global $ID, $conf; @@ -891,6 +932,9 @@ function html_list_index($item){ * it gives different classes to opened or closed "folders" * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param array $item + * @return string html */ function html_li_index($item){ if($item['type'] == "f"){ @@ -906,6 +950,9 @@ function html_li_index($item){ * Default List item * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param array $item + * @return string html */ function html_li_default($item){ return '<li class="level'.$item['level'].'">'; @@ -929,7 +976,7 @@ function html_li_default($item){ * @param array $data array with item arrays * @param string $class class of ul wrapper * @param callable $func callback to print an list item - * @param string $lifunc callback to the opening li tag + * @param callable $lifunc callback to the opening li tag * @param bool $forcewrapper Trigger building a wrapper ul if the first level is 0 (we have a root object) or 1 (just the root content) * @return string html of an unordered list @@ -1021,12 +1068,13 @@ function html_backlinks(){ /** * Get header of diff HTML + * * @param string $l_rev Left revisions * @param string $r_rev Right revision * @param string $id Page id, if null $ID is used * @param bool $media If it is for media files * @param bool $inline Return the header on a single line - * @return array HTML snippets for diff header + * @return string[] HTML snippets for diff header */ function html_diff_head($l_rev, $r_rev, $id = null, $media = false, $inline = false) { global $lang; @@ -1482,7 +1530,7 @@ function html_diff_navigationlink($difftype, $linktype, $lrev, $rrev = null) { /** * Insert soft breaks in diff html * - * @param $diffhtml + * @param string $diffhtml * @return string */ function html_insert_softbreaks($diffhtml) { @@ -1521,6 +1569,9 @@ REGEX; * show warning on conflict detection * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param string $text + * @param string $summary */ function html_conflict($text,$summary){ global $ID; @@ -1681,7 +1732,6 @@ function html_edit(){ global $lang; global $conf; global $TEXT; - global $RANGE; if ($INPUT->has('changecheck')) { $check = $INPUT->str('changecheck'); @@ -1783,6 +1833,7 @@ function html_edit(){ * Display the default edit form * * Is the default action for HTML_EDIT_FORMSELECTION. + * * @param mixed[] $param */ function html_edit_form($param) { @@ -1802,6 +1853,8 @@ function html_edit_form($param) { * Adds a checkbox for minor edits for logged in users * * @author Andreas Gohr <andi@splitbrain.org> + * + * @return array|bool */ function html_minoredit(){ global $conf; @@ -1902,6 +1955,7 @@ function html_debug(){ print '</pre>'; if (function_exists('apache_get_version')) { + $apache = array(); $apache['version'] = apache_get_version(); if (function_exists('apache_get_modules')) { @@ -2080,6 +2134,9 @@ function html_resendpwd() { * Return the TOC rendered to XHTML * * @author Andreas Gohr <andi@splitbrain.org> + * + * @param array $toc + * @return string html */ function html_TOC($toc){ if(!count($toc)) return ''; @@ -2098,6 +2155,9 @@ function html_TOC($toc){ /** * Callback for html_buildlist + * + * @param array $item + * @return string html */ function html_list_toc($item){ if(isset($item['hid'])){ @@ -2132,6 +2192,7 @@ function html_mktocitem($link, $text, $level, $hash='#'){ * Triggers an event with the form name: HTML_{$name}FORM_OUTPUT * * @author Tom N Harris <tnharris@whoopdedo.org> + * * @param string $name The name of the form * @param Doku_Form $form The form */ @@ -2144,6 +2205,7 @@ function html_form($name, &$form) { /** * Form print function. * Just calls printForm() on the data object. + * * @param Doku_Form $data The form */ function html_form_output($data) { |