diff --git a/assets/php/template.php b/assets/php/template.php
index 318b377..79ec6a2 100644
--- a/assets/php/template.php
+++ b/assets/php/template.php
@@ -159,59 +159,61 @@
//Print panel menu:
function print_panelMenu($panel){
- $prefix = $this->prefix;
- $menus = array("Panel Principal");
+ if($_SESSION["login"]){
+ $prefix = $this->prefix;
+ $menus = array("Panel Principal");
- switch($panel){
- case "admin": array_push($menus, "
Ver como...
-
- ");
- array_push($menus, "Modificar
-
- ");
- break;
+ switch($panel){
+ case "admin": array_push($menus, "Ver como...
+
+ ");
+ array_push($menus, "Modificar
+
+ ");
+ break;
- case "manager": array_push($menus, "Ver como...
-
- ");
- array_push($menus, "Modificar
-
- ");
- break;
+ case "manager": array_push($menus, "Ver como...
+
+ ");
+ array_push($menus, "Modificar
+
+ ");
+ break;
- case "user": array_push($menus, "Historial Compras");
- array_push($menus, "Datos Pago");
- array_push($menus, "Contraseña");
- array_push($menus, "Eliminar Usuario");
- break;
+ case "user": array_push($menus, "Historial Compras");
+ array_push($menus, "Datos Pago");
+ array_push($menus, "Contraseña");
+ array_push($menus, "Eliminar Usuario");
+ break;
- default: $menus = array(); break;
+ default: $menus = array(); break;
+ }
+
+ echo"\n";
}
-
- echo"\n";
}
//Print session MSG: