mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-27 02:14:45 +01:00
Added fp() finish parse short cut
This commit is contained in:
parent
ede96854ab
commit
4b932ff6df
@ -193,8 +193,14 @@ class Template {
|
||||
return false;
|
||||
}
|
||||
|
||||
// This is short for finish parse
|
||||
function fp($target, $handle, $append = False)
|
||||
{
|
||||
return $this->finish($this->parse($target, $handle, $append));
|
||||
}
|
||||
|
||||
// This is a short cut for print finish parse
|
||||
function pfp($target, $handle, $append = false)
|
||||
function pfp($target, $handle, $append = False)
|
||||
{
|
||||
echo $this->finish($this->parse($target, $handle, $append));
|
||||
}
|
||||
@ -336,17 +342,24 @@ class Template {
|
||||
/* public: halt(string $msg)
|
||||
* msg: error message to show.
|
||||
*/
|
||||
function halt($msg) {
|
||||
$this->last_error = $msg;
|
||||
function halt($msg)
|
||||
{
|
||||
global $phpgw;
|
||||
|
||||
$this->last_error = $msg;
|
||||
|
||||
if ($this->halt_on_error != "no")
|
||||
$this->haltmsg($msg);
|
||||
if ($this->halt_on_error != 'no')
|
||||
{
|
||||
$this->haltmsg($msg);
|
||||
}
|
||||
|
||||
if ($this->halt_on_error == "yes")
|
||||
die("<b>Halted.</b>");
|
||||
|
||||
return false;
|
||||
}
|
||||
if ($this->halt_on_error == 'yes')
|
||||
{
|
||||
echo('<b>Halted.</b>');
|
||||
}
|
||||
|
||||
$phpgw->common->phpgw_exit(True);
|
||||
}
|
||||
|
||||
/* public, override: haltmsg($msg)
|
||||
* msg: error message to show.
|
||||
|
Loading…
Reference in New Issue
Block a user