From 465a1309af4013eb9ffbd352ec68e232ae027593 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 10:47:14 -0800 Subject: [PATCH] Session clear() with no key will now reset data array. Fix for nav-bar avatar alignment --- e107_handlers/session_handler.php | 12 ++++++++++-- e107_themes/bootstrap3/style.css | 2 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/e107_handlers/session_handler.php b/e107_handlers/session_handler.php index 86f4e6f6e..9d73a51e1 100644 --- a/e107_handlers/session_handler.php +++ b/e107_handlers/session_handler.php @@ -333,8 +333,13 @@ class e_session * @param string $key * @return e_session */ - public function clear($key) + public function clear($key=null) { + if($key == null) // clear all under this namespace. + { + $this->_data = array(); // must be set to array() not unset. + } + unset($this->_data[$key]); return $this; } @@ -451,7 +456,10 @@ class e_session break; default: - session_module_name('files'); + if(!isset($_SESSION)) + { + session_module_name('files'); + } break; } diff --git a/e107_themes/bootstrap3/style.css b/e107_themes/bootstrap3/style.css index 2dfe3a42a..f41b35ae9 100644 --- a/e107_themes/bootstrap3/style.css +++ b/e107_themes/bootstrap3/style.css @@ -143,7 +143,7 @@ table label.checkbox { #sidebar .panel-body ul.list-unstyled { padding-left:0} - +li.dropdown-avatar > a.dropdown-toggle { padding:0; padding-top:9px; padding-bottom:10px}