\Pop\View\TemplateFile

View file template class

Summary

Methods
Properties
Constants
getTemplate()
setTemplate()
render()
__construct()
No public properties found
No constants found
renderTemplate()
$template
$data
$output
N/A
No private methods found
No private properties found
N/A

Properties

$template

$template : string

View template

Type

string

$data

$data : array

View data

Type

array

$output

$output : string

View output string

Type

string

Methods

getTemplate()

getTemplate() : string

Get view template

Returns

string

setTemplate()

setTemplate(string  $template) : \Pop\View\Template\File

Set view template

Parameters

string $template

Throws

\Pop\View\Template\Exception

Returns

\Pop\View\Template\File

render()

render(array  $data = null) : string

Render the view and return the output

Parameters

array $data

Returns

string

__construct()

__construct(string  $template) 

Constructor

Instantiate the view file template object

Parameters

string $template

renderTemplate()

renderTemplate() : void

Render view template file

Throws

\Exception