for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Template.php - Trait for template functions
*
* @package jaxon-core
* @author Thierry Feuzeu <[email protected]>
* @copyright 2016 Thierry Feuzeu <[email protected]>
* @license https://opensource.org/licenses/BSD-3-Clause BSD 3-Clause License
* @link https://github.com/jaxon-php/jaxon-core
*/
namespace Jaxon\Traits;
use Jaxon\DI\Container;
trait Template
{
* Add a namespace to the template system
* @param string $sNamespace The namespace name
* @param string $sDirectory The namespace directory
* @param string $sExtension The extension to append to template names
* @return void
public function addViewNamespace($sNamespace, $sDirectory, $sExtension = '')
return Container::getInstance()->getTemplate()->addNamespace($sNamespace, $sDirectory, $sExtension);
}
* Set a new directory for pagination templates
* @param string $sDirectory The directory path
public function setPaginationDir($sDirectory)
return Container::getInstance()->getTemplate()->setPaginationDir($sDirectory);