display currently logged in username

This commit is contained in:
Sanjay B 2013-09-04 15:07:57 +05:30
parent 3a19473a4b
commit 8bd2584ffb
2 changed files with 15 additions and 8 deletions

View File

@ -272,7 +272,13 @@ cursor:pointer;
z-index:2;
clear:both;}
#loginMenu li
#loginMenu li.usernameDisplay {
float: left;
display: inline;
padding: 6px 6px;
}
#loginMenu li.loginTab
{display:inline;
float:left;
background-color:#FFF;
@ -288,16 +294,16 @@ border-top-left-radius:8px;
-webkit-box-shadow:0px -1px 3px #d4d4d4;
box-shadow:0px -1px 3px #d4d4d4;}/*not converted to links*/
#loginMenu li a, #loginMenu li a:link, #loginMenu li a:visited, #loginMenu li a:active
#loginMenu li.loginTab a, #loginMenu li.loginTab a:link, #loginMenu li.loginTab a:visited, #loginMenu li.loginTab a:active
{text-decoration:none;
color:#ff8400;}
#loginMenu li:hover
#loginMenu li.loginTab:hover
{color:#FFF;
background-color:#f7bd00;
border:1px solid transparent;}
#loginMenu li:hover a
#loginMenu li.loginTab:hover a
{color:#FFF;}
.loginMenuSelected

View File

@ -48,13 +48,14 @@
<ul id="loginMenu">
{% if user.is_authenticated %}
<li><a href="/accounts/logout">Logout</a></li>
<li class="usernameDisplay">Hi {{ user.username }}</li>
<li class="loginTab"><a href="/accounts/logout">Logout</a></li>
{% else %}
<li><a href="/accounts/login">Login</a></li>
<li><a href="/accounts/signup">Register</a></li>
<li class="loginTab"><a href="/accounts/login">Login</a></li>
<li class="loginTab"><a href="/accounts/signup">Register</a></li>
{% endif %}
<li><a href="/contact">Contact Us</a></li>
<li class="loginTab"><a href="/contact">Contact Us</a></li>
</ul>
</div>