From 2ee30c8128a464386f87be428f3ab3061d073e40 Mon Sep 17 00:00:00 2001 From: raul Date: Tue, 24 Jun 2014 11:58:54 -0300 Subject: [i18n] implemented translator logic --- index.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'index.php') diff --git a/index.php b/index.php index e5782e6a..a3f5384e 100644 --- a/index.php +++ b/index.php @@ -3,7 +3,9 @@ require_once 'config.php'; require_once 'dictionary.php'; +Dictionary::build(); +require_once('inc/user.inc.php'); /** * Page class which all "modules" must be extending from @@ -115,8 +117,11 @@ if (AJAX) { Page::preprocess(); // Generate Main menu -$menu = new Menu; -Render::addTemplate('main-menu', $menu); +//$menu = new Menu; +if(User::getName() === false) Render::addTemplate('main-menu-login'); +else Render::addTemplate('main-menu-logout',array( + 'user' => User::getName() + )); Message::renderList(); -- cgit v1.2.3-55-g7522