| @@ 30-44 (lines=15) @@ | ||
| 27 | * |
|
| 28 | * @return null|string |
|
| 29 | */ |
|
| 30 | public function before($return = false, $nesting = 1) |
|
| 31 | { |
|
| 32 | if (empty($this->before)) { |
|
| 33 | return null; |
|
| 34 | } |
|
| 35 | ||
| 36 | $html = implode("\n".str_repeat("\t", $nesting), $this->before).PHP_EOL; |
|
| 37 | ||
| 38 | if (false === $return) { |
|
| 39 | echo $html; |
|
| 40 | return null; |
|
| 41 | } |
|
| 42 | ||
| 43 | return $html; |
|
| 44 | } |
|
| 45 | ||
| 46 | /** |
|
| 47 | * Get before array. |
|
| @@ 80-94 (lines=15) @@ | ||
| 77 | * |
|
| 78 | * @return null|string |
|
| 79 | */ |
|
| 80 | public function after($return = false, $nesting = 1) |
|
| 81 | { |
|
| 82 | if (empty($this->after)) { |
|
| 83 | return null; |
|
| 84 | } |
|
| 85 | ||
| 86 | $html = implode("\n".str_repeat("\t", $nesting), $this->after).PHP_EOL; |
|
| 87 | ||
| 88 | if (false === $return) { |
|
| 89 | echo $html; |
|
| 90 | return null; |
|
| 91 | } |
|
| 92 | ||
| 93 | return $html; |
|
| 94 | } |
|
| 95 | ||
| 96 | /** |
|
| 97 | * Get after array. |
|