@@ -268,7 +268,7 @@ discard block |
||
| 268 | 268 | * |
| 269 | 269 | * Info: Additional variables passed to the functions hooked to <tt>$tag</tt>. |
| 270 | 270 | * |
| 271 | - * @param string|array $tag The name of the filter hook. |
|
| 271 | + * @param Hooks[] $tag The name of the filter hook. |
|
| 272 | 272 | * @param mixed $value The value on which the filters hooked to <tt>$tag</tt> are applied on. |
| 273 | 273 | * |
| 274 | 274 | * @return mixed The filtered value after all hooked functions are applied to it. |
@@ -671,7 +671,7 @@ discard block |
||
| 671 | 671 | * |
| 672 | 672 | * @param string|array $function Used for creating unique id |
| 673 | 673 | * |
| 674 | - * @return string|bool Unique ID for usage as array key or false if |
|
| 674 | + * @return string|false Unique ID for usage as array key or false if |
|
| 675 | 675 | * $priority === false and $function is an |
| 676 | 676 | * object reference, and it does not already have a unique id. |
| 677 | 677 | * @access private |
@@ -993,7 +993,7 @@ discard block |
||
| 993 | 993 | * |
| 994 | 994 | * @param array $m Regular expression match array |
| 995 | 995 | * |
| 996 | - * @return mixed False on failure. |
|
| 996 | + * @return string False on failure. |
|
| 997 | 997 | */ |
| 998 | 998 | private function _do_shortcode_tag($m) |
| 999 | 999 | { |
@@ -254,7 +254,7 @@ discard block |
||
| 254 | 254 | return false; |
| 255 | 255 | } |
| 256 | 256 | |
| 257 | - foreach ((array)array_keys($this->filters[$tag]) as $priority) { |
|
| 257 | + foreach ((array) array_keys($this->filters[$tag]) as $priority) { |
|
| 258 | 258 | if (isset($this->filters[$tag][$priority][$idx])) { |
| 259 | 259 | return $priority; |
| 260 | 260 | } |
@@ -313,7 +313,7 @@ discard block |
||
| 313 | 313 | array_shift($args); |
| 314 | 314 | |
| 315 | 315 | do { |
| 316 | - foreach ((array)current($this->filters[$tag]) as $the_) { |
|
| 316 | + foreach ((array) current($this->filters[$tag]) as $the_) { |
|
| 317 | 317 | if (null !== $the_['function']) { |
| 318 | 318 | |
| 319 | 319 | if (null !== $the_['include_path']) { |
@@ -373,7 +373,7 @@ discard block |
||
| 373 | 373 | reset($this->filters[$tag]); |
| 374 | 374 | |
| 375 | 375 | do { |
| 376 | - foreach ((array)current($this->filters[$tag]) as $the_) { |
|
| 376 | + foreach ((array) current($this->filters[$tag]) as $the_) { |
|
| 377 | 377 | if (null !== $the_['function']) { |
| 378 | 378 | |
| 379 | 379 | if (null !== $the_['include_path']) { |
@@ -524,7 +524,7 @@ discard block |
||
| 524 | 524 | && |
| 525 | 525 | 1 == count($arg) |
| 526 | 526 | ) { |
| 527 | - $args[] =& $arg[0]; |
|
| 527 | + $args[] = & $arg[0]; |
|
| 528 | 528 | } else { |
| 529 | 529 | $args[] = $arg; |
| 530 | 530 | } |
@@ -544,7 +544,7 @@ discard block |
||
| 544 | 544 | reset($this->filters[$tag]); |
| 545 | 545 | |
| 546 | 546 | do { |
| 547 | - foreach ((array)current($this->filters[$tag]) as $the_) { |
|
| 547 | + foreach ((array) current($this->filters[$tag]) as $the_) { |
|
| 548 | 548 | if (null !== $the_['function']) { |
| 549 | 549 | |
| 550 | 550 | if (null !== $the_['include_path']) { |
@@ -612,7 +612,7 @@ discard block |
||
| 612 | 612 | reset($this->filters[$tag]); |
| 613 | 613 | |
| 614 | 614 | do { |
| 615 | - foreach ((array)current($this->filters[$tag]) as $the_) { |
|
| 615 | + foreach ((array) current($this->filters[$tag]) as $the_) { |
|
| 616 | 616 | if (null !== $the_['function']) { |
| 617 | 617 | |
| 618 | 618 | if (null !== $the_['include_path']) { |
@@ -690,17 +690,17 @@ discard block |
||
| 690 | 690 | '', |
| 691 | 691 | ); |
| 692 | 692 | } else { |
| 693 | - $function = (array)$function; |
|
| 693 | + $function = (array) $function; |
|
| 694 | 694 | } |
| 695 | 695 | |
| 696 | 696 | if (is_object($function[0])) { |
| 697 | 697 | // Object Class Calling |
| 698 | - return spl_object_hash($function[0]) . $function[1]; |
|
| 698 | + return spl_object_hash($function[0]).$function[1]; |
|
| 699 | 699 | } |
| 700 | 700 | |
| 701 | 701 | if (is_string($function[0])) { |
| 702 | 702 | // Static Calling |
| 703 | - return $function[0] . $function[1]; |
|
| 703 | + return $function[0].$function[1]; |
|
| 704 | 704 | } |
| 705 | 705 | |
| 706 | 706 | return false; |
@@ -722,7 +722,7 @@ discard block |
||
| 722 | 722 | reset($this->filters['all']); |
| 723 | 723 | |
| 724 | 724 | do { |
| 725 | - foreach ((array)current($this->filters['all']) as $the_) { |
|
| 725 | + foreach ((array) current($this->filters['all']) as $the_) { |
|
| 726 | 726 | if (null !== $the_['function']) { |
| 727 | 727 | |
| 728 | 728 | if (null !== $the_['include_path']) { |
@@ -876,7 +876,7 @@ discard block |
||
| 876 | 876 | } |
| 877 | 877 | |
| 878 | 878 | if ($this->shortcode_exists($tag)) { |
| 879 | - preg_match_all('/' . $this->get_shortcode_regex() . '/s', $content, $matches, PREG_SET_ORDER); |
|
| 879 | + preg_match_all('/'.$this->get_shortcode_regex().'/s', $content, $matches, PREG_SET_ORDER); |
|
| 880 | 880 | if (empty($matches)) { |
| 881 | 881 | return false; |
| 882 | 882 | } |
@@ -1007,11 +1007,11 @@ discard block |
||
| 1007 | 1007 | |
| 1008 | 1008 | // enclosing tag - extra parameter |
| 1009 | 1009 | if (isset($m[5])) { |
| 1010 | - return $m[1] . call_user_func(self::$shortcode_tags[$tag], $attr, $m[5], $tag) . $m[6]; |
|
| 1010 | + return $m[1].call_user_func(self::$shortcode_tags[$tag], $attr, $m[5], $tag).$m[6]; |
|
| 1011 | 1011 | } |
| 1012 | 1012 | |
| 1013 | 1013 | // self-closing tag |
| 1014 | - return $m[1] . call_user_func(self::$shortcode_tags[$tag], $attr, null, $tag) . $m[6]; |
|
| 1014 | + return $m[1].call_user_func(self::$shortcode_tags[$tag], $attr, null, $tag).$m[6]; |
|
| 1015 | 1015 | } |
| 1016 | 1016 | |
| 1017 | 1017 | /** |
@@ -1073,7 +1073,7 @@ discard block |
||
| 1073 | 1073 | */ |
| 1074 | 1074 | public function shortcode_atts($pairs, $atts, $shortcode = '') |
| 1075 | 1075 | { |
| 1076 | - $atts = (array)$atts; |
|
| 1076 | + $atts = (array) $atts; |
|
| 1077 | 1077 | $out = array(); |
| 1078 | 1078 | foreach ($pairs as $name => $default) { |
| 1079 | 1079 | if (array_key_exists($name, $atts)) { |
@@ -1150,7 +1150,7 @@ discard block |
||
| 1150 | 1150 | return substr($m[0], 1, -1); |
| 1151 | 1151 | } |
| 1152 | 1152 | |
| 1153 | - return $m[1] . $m[6]; |
|
| 1153 | + return $m[1].$m[6]; |
|
| 1154 | 1154 | } |
| 1155 | 1155 | |
| 1156 | 1156 | } |