@@ -200,6 +200,9 @@ discard block |
||
| 200 | 200 | return false; |
| 201 | 201 | } |
| 202 | 202 | |
| 203 | + /** |
|
| 204 | + * @param string|boolean $layout |
|
| 205 | + */ |
|
| 203 | 206 | public function setLayout($layout) |
| 204 | 207 | { |
| 205 | 208 | if ($layout === false) { |
@@ -241,6 +244,10 @@ discard block |
||
| 241 | 244 | * @return string processed content |
| 242 | 245 | */ |
| 243 | 246 | //@TODO: come back and clean up this and the way the view receives stuff |
| 247 | + |
|
| 248 | + /** |
|
| 249 | + * @param string|boolean $file |
|
| 250 | + */ |
|
| 244 | 251 | private function process($file) |
| 245 | 252 | { |
| 246 | 253 | ob_start(); |
@@ -1,6 +1,5 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Zewa; |
| 3 | -use Zewa\Interfaces\ContainerInterface; |
|
| 4 | 3 | |
| 5 | 4 | /** |
| 6 | 5 | * View management |
@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | |
| 135 | 135 | $this->view = $return = $this->process($view); |
| 136 | 136 | |
| 137 | - if(! is_null($this->layout) ) { |
|
| 137 | + if (!is_null($this->layout)) { |
|
| 138 | 138 | $return = $this->process($this->layout); |
| 139 | 139 | } |
| 140 | 140 | |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | $this->view = $this->process($this->view); |
| 145 | 145 | } |
| 146 | 146 | |
| 147 | - if (! is_null($this->layout)) { |
|
| 147 | + if (!is_null($this->layout)) { |
|
| 148 | 148 | return $this->process($this->layout); |
| 149 | 149 | } else { |
| 150 | 150 | return $this->view; |
@@ -274,7 +274,7 @@ discard block |
||
| 274 | 274 | } |
| 275 | 275 | |
| 276 | 276 | foreach ($this->queuedCSS as $sheet) { |
| 277 | - $string .= '<link rel="stylesheet" href="' . $sheet .'">' . "\r\n"; |
|
| 277 | + $string .= '<link rel="stylesheet" href="' . $sheet . '">' . "\r\n"; |
|
| 278 | 278 | } |
| 279 | 279 | |
| 280 | 280 | return $string; |