From 7e7a0458a5b710a7634938183eca927bb4dcc371 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Thu, 15 Jan 2009 11:08:54 -0500 Subject: [PATCH] Create a toString method for BSTemplate that will evaluate it * Template.php: (BSTemplate::__toString): Implemented to call evaluate()->getTemplate() * version.php: Bumping the version number --- CHANGES | 4 ++++ Template.php | 11 +++++++++++ version.php | 2 +- 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index cc55eb4..b413b8d 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,7 @@ +3.2.2 +=================== +- New: Added BSTemplate::__toString() to evaluate the template + 3.2.1 =================== - New: BSFunctions::bool_to_string() to convert a boolean value into human-readable Yes/No diff --git a/Template.php b/Template.php index aeb8a72..dfe30c1 100644 --- a/Template.php +++ b/Template.php @@ -178,6 +178,17 @@ class BSTemplate } } + /** + * Evaluates and returns the template. This is equivalent to calling: + * $tpl->evaluate()->getTemplate() + * + * @return string + */ + public function __toString() + { + return $this->evaluate()->getTemplate(); + } + /** * Returns the template data * diff --git a/version.php b/version.php index e43dfb4..83043fe 100644 --- a/version.php +++ b/version.php @@ -22,6 +22,6 @@ /** * ISSO version */ -define('ISSO_VERSION', '3.2.1'); +define('ISSO_VERSION', '3.2.2'); ?> \ No newline at end of file -- 2.43.5