XOOPS
2.6.0
Main Page
Related Pages
Classes
Files
Examples
File List
File Members
AbstractTemplate.php
Go to the documentation of this file.
1
<?php
2
/*
3
You may not change or alter any portion of this comment or credits
4
of supporting developers from this source code or any supporting source code
5
which is considered copyrighted (c) material of the original comment or credit authors.
6
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10
*/
11
12
namespace
Xmf\Template
;
13
27
abstract
class
AbstractTemplate
28
{
32
protected
$tpl
;
33
37
private
$template
;
38
42
public
function
__construct
()
43
{
44
$this->tpl = new \XoopsTpl();
45
$this->
template
=
"module:system/system_dummy.tpl"
;
46
$this->
init
();
47
}
48
54
abstract
protected
function
init
();
55
61
abstract
protected
function
render
();
62
70
protected
function
setTemplate
(
$template
=
''
)
71
{
72
$this->
template
=
$template
;
73
}
74
80
protected
function
disableLogger
()
81
{
82
\Xoops::getInstance
()->logger()->quiet();
83
}
84
90
public
function
fetch
()
91
{
92
$this->
render
();
93
94
return
$this->tpl->fetch($this->
template
);
95
}
96
102
public
function
display
()
103
{
104
echo $this->
fetch
();
105
}
106
}
Xmf\Template
Definition:
AbstractTemplate.php:12
Xmf\Template\AbstractTemplate\__construct
__construct()
Definition:
AbstractTemplate.php:42
Xmf\Template\AbstractTemplate\init
init()
Xoops\getInstance
static getInstance()
Definition:
Xoops.php:160
Xmf\Template\AbstractTemplate\fetch
fetch()
Definition:
AbstractTemplate.php:90
Xmf\Template\AbstractTemplate\render
render()
Xmf\Template\AbstractTemplate\display
display()
Definition:
AbstractTemplate.php:102
Xmf\Template\AbstractTemplate\setTemplate
setTemplate($template= '')
Definition:
AbstractTemplate.php:70
Xmf\Template\AbstractTemplate\$tpl
$tpl
Definition:
AbstractTemplate.php:32
Xmf\Template\AbstractTemplate\$template
$template
Definition:
AbstractTemplate.php:37
Xmf\Template\AbstractTemplate
Definition:
AbstractTemplate.php:27
Xmf\Template\AbstractTemplate\disableLogger
disableLogger()
Definition:
AbstractTemplate.php:80
usr64
htdocs
xoops_lib
Xmf
Template
AbstractTemplate.php
Generated on Fri May 22 2015 03:07:05 for XOOPS by
1.8.9.1