From 75095b0329236ea0e2522a633f4a2be733d6869b Mon Sep 17 00:00:00 2001 From: Antonio Gallo Date: Sat, 8 Oct 2011 09:09:05 +0000 Subject: improved the way text can be written inside modules of the website --- h-source/Application/Controllers/HomeController.php | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) (limited to 'h-source/Application/Controllers/HomeController.php') diff --git a/h-source/Application/Controllers/HomeController.php b/h-source/Application/Controllers/HomeController.php index 5eff4d9..96479f3 100644 --- a/h-source/Application/Controllers/HomeController.php +++ b/h-source/Application/Controllers/HomeController.php @@ -37,20 +37,13 @@ class HomeController extends BaseController public function index($lang = 'en') { // get the news container - $this->m['BoxesModel']->setWhereQueryClause(array('title'=>'home_news')); - $boxes = $this->m['BoxesModel']->getAll('boxes'); - - if (count($boxes) > 0) + $data['htmlNewsBox'] = null; + $xml = $this->getBox(array('top_news')); + if ($xml) { - $xml = htmlspecialchars_decode($boxes[0]['boxes']['message'],ENT_QUOTES); - $box_news = new BoxParser($xml); $data['htmlNewsBox'] = $box_news->render(); } - else - { - $data['htmlNewsBox'] = null; - } $this->append($data); $this->cleverLoad('left'); -- cgit v1.2.3