From 4c1557038acf9e5b6597372dfe090eef4cf7b1e9 Mon Sep 17 00:00:00 2001 From: xq2005 Date: Tue, 14 Sep 2010 02:33:16 +0000 Subject: [PATCH] add log out button git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@7442 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-UI/css/style.css | 16 ++++++++++++++++ xCAT-UI/lib/ui.php | 9 +++++++-- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/xCAT-UI/css/style.css b/xCAT-UI/css/style.css index b3d4b05dc..da94e778b 100644 --- a/xCAT-UI/css/style.css +++ b/xCAT-UI/css/style.css @@ -15,6 +15,7 @@ /****************** Header ******************/ #header { + height : 40px; width: 1000px; margin: 0px auto; background: url(../images/header-gloss-wave.png) 50% 50% repeat-x; @@ -25,6 +26,7 @@ } #header ul { + float : left; list-style: none; padding: 0 0 0 30px; margin: 0; @@ -51,6 +53,20 @@ background-color: #A9D0F5; } +/* for usernamed login */ +#header div { + float: right; + margin-right: 10px; + padding-right: 5px; + text-align: right; + font-size: 1em; +} +#header div span { + color: yellow; +} +#header div a { + color: #ddd; +} /****************** Content section ******************/ body { background-color: #1C1C1C; diff --git a/xCAT-UI/lib/ui.php b/xCAT-UI/lib/ui.php index 06a94adc7..a5d228eb5 100644 --- a/xCAT-UI/lib/ui.php +++ b/xCAT-UI/lib/ui.php @@ -32,9 +32,14 @@ function loadPage(){
  • Configure
  • Provision
  • Monitor
  • - - '; + '; + + if (isset($_SESSION['username'])){ + echo "
    user: {$_SESSION['username']}". + "
    log out
    "; + } + echo ''; // Content echo '
    ';