From fb64d50a0ed13138ec20b3217ca08620f3eea94e Mon Sep 17 00:00:00 2001 From: Antonio de la Rosa Date: Tue, 12 May 2015 02:47:09 +0200 Subject: [PATCH] Fix on variables --- src/View.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/View.php b/src/View.php index d2891b2..6570b41 100644 --- a/src/View.php +++ b/src/View.php @@ -547,6 +547,30 @@ class View { } + static public function set_flash($text) + { + + $_SESSION['flash_txt']=$text; + + } + + static public function show_flash() + { + + if(isset($_SESSION['flash_txt'])) + { + if($_SESSION['flash_txt']!='') + { + + return View::loadView(array($_SESSION['flash_txt']), 'flash'); + + } + } + + return ''; + + } + } ?> \ No newline at end of file