TYPO3  7.6
install/Classes/ViewHelpers/Be/ContainerViewHelper.php
Go to the documentation of this file.
1 <?php
2 namespace TYPO3\CMS\Install\ViewHelpers\Be;
3 
4 /*
5  * This file is part of the TYPO3 CMS project.
6  *
7  * It is free software; you can redistribute it and/or modify it under
8  * the terms of the GNU General Public License, either version 2
9  * of the License, or any later version.
10  *
11  * For the full copyright and license information, please read the
12  * LICENSE.txt file that was distributed with this source code.
13  *
14  * The TYPO3 project - inspiring people to share!
15  */
16 
43 {
55  public function render($pageTitle = '', $addCssFiles = array(), $addJsFiles = array())
56  {
57  $doc = $this->getDocInstance();
58  $pageRenderer = $this->getPageRenderer();
59 
60  if (is_array($addCssFiles) && !empty($addCssFiles)) {
61  foreach ($addCssFiles as $addCssFile) {
62  $pageRenderer->addCssFile($addCssFile);
63  }
64  }
65  if (is_array($addJsFiles) && !empty($addJsFiles)) {
66  foreach ($addJsFiles as $addJsFile) {
67  $pageRenderer->addJsFile($addJsFile);
68  }
69  }
70  $output = $this->renderChildren();
71  $output = $doc->startPage($pageTitle) . $output;
72  $output .= $doc->endPage();
73  return $output;
74  }
75 }