Display name of the connected user

This commit is contained in:
Phyks 2013-08-30 22:33:06 +02:00
parent 51f3aa1491
commit 63f0d881a8
5 changed files with 24 additions and 6 deletions

2
TODO
View File

@ -14,9 +14,9 @@ Manage paybacks :
TODO :
======
* Colgroups + CSS hover
* Add / Edit a bill
* JSON output
* Arrow to toggle visible password
To test :
=========

View File

@ -1,8 +1,7 @@
<?php
// Generates a token against CSRF
// ==============================
function generate_token($name = '')
{
function generate_token($name = '') {
if(session_id() == '')
session_start();
@ -16,8 +15,7 @@
// Checks that the anti-CSRF token is correct
// ==========================================
function check_token($time, $name = '')
{
function check_token($time, $name = '') {
if(session_id() == '')
session_start();

View File

@ -1,4 +1,11 @@
html {
height: 100%;
}
body {
position: relative;
padding-bottom: 2em;
min-height: calc(100% - 2em);
font-family: sans-serif;
margin: 0;
}
@ -127,6 +134,17 @@ textarea#what {
background-color: #00bd00;
}
#user_connected {
text-align: right;
margin-right: 1em;
position: absolute;
bottom: 0;
height: 1em;
font-size: 0.75em;
right: 0;
font-style: italic;
}
#install {
margin: 0;
}

View File

@ -1,3 +1,6 @@
{if condition="!$connection"}
<p id="user_connected">Connected as {$current_user->getDisplayName()}.</p>
{/if}
<script type="text/javascript" src="js/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="js/main.js"></script>
</body>

View File

@ -50,5 +50,4 @@
{/loop}
</table>
</div>
{include="footer"}