This page shows user's usage. We need to improve it. help

Replace the status page code with this to show the user its usage. But we want to improve this page because it shows only user’s usage of the current session. means it takes the information of the user from ACTIVE page. please help us to improve this code to get the to show the user its total usage. We want this page to read bytes-out, bytes-in, uptime…etc.

<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<title>status</title>
</head>

<body>

<table border="2" style="border-collapse: collapse" bordercolor="black" cellpadding="6" align="center">

    <tr>
        <td align="left"><b><font face="Arial">Your IP</font></b></td>
        <td align="left"><b><font color="red" face="Arial">$(ip)</font></b></td>

    </tr>
    <tr>
<td align="left"><b><font face="Arial">User Name</font></b></td>
        <td align="left"><b><font color="red" face="Arial">$(username)</font></b></td>
        
    </tr>
    <tr>
 <td align="left"><b><font face="Arial">Upload/Download</font></b></td>
<td align="left"><b><font color="red" face="Arial">$(bytes-in-nice) / $(bytes-out-nice)</font></b></td>
        
        
    </tr>
    <b><font color="red" face="Arial">$(if session-time-left)
    </font></b>
    <tr>
<td align="left"><b><font face="Arial">Remaining Time</font></b></td>
        <td align="left"><b><font color="red" face="Arial">&nbsp;$(session-time-left)</font></b></td>
        
    </tr>
    <b><font color="red" face="Arial">$(else)
    </font></b>
    <tr>
        <td align="left"><b><font face="Arial">Your current session</font></b></td>
        <td align="left"><b><font color="red" face="Arial">$(uptime)</font></b></td>

    </tr>
    <b><font color="red" face="Arial">$(endif) $(if blocked == 'yes')
    </font></b>
    <tr>
        <td align="left"><div style="color: #FF8080"><b><font face="Arial"><a href="$(link-advert)" target="hotspot_advert"><font color="red">advertisement</font></a><font color="red"> required</font></font></b></div></td>    
        <td align="left"><b><font face="Arial">Status</font></b></td>
    </tr>    
        <b><font color="red" face="Arial">$(elif refresh-timeout)
    </font></b>
    <tr>
        <td align="left"><b><font face="Arial">Update all </font></b></td>
        <td align="left"><b><font color="red" face="Arial">$(refresh-timeout)</font></b></td>

    </tr>
        <b><font color="red" face="Arial">$(endif)
        </font></b>
</table>
</body>

</html>

dear,

The following constants of voucher template will be replaced with actual user attribute values:
%u_username% - Username (login);
%u_password% - Password;
%u_owner% - User Manager customer;
%u_firstName% - First name;
%u_lastName% - Last name;
%u_phone% - Phone number;
%u_location% - Location;
%u_email% - Email address;
%u_comment% - Comment;
%u_ipAddr% - IP address;
%u_pool% - Pool name;
%u_group% - Group;
%u_limit_download_f% - Nicely formatted download limit (introduced in v3.1);
%u_limit_upload_f% - Nicely formatted upload limit (introduced in v3.1);
%u_limit_transfer_f% - Nicely formatted transfer limit (introduced in v3.1);
%u_limitDownload% - Download limit (in bytes);
%u_limitUpload% - Upload limit (in bytes);
%u_limitUptime% - Uptime limit (in time);
%u_usedDownload% - Used download;
%u_usedUpload% - Used upload;
%u_usedUptime% - Used uptime;
%u_prep_time% - Prepaid time - time constant or the word unlimited;
%u_tot_price% - Total price, including currency;
%u_callerId% - Caller-id information;
%u_shared_users% - Number of shared users;
%u_wirelessPsk% - Wireless WPA/WPA2 pre-shared key;
%u_wirelessEncKey% - Wireless WEP key;
%u_wirelessEncAlgo% - Wireless Encryption Algorithm;
%u_tillTime% - Time available for users (Profile Validity);
%u_timeLeft% - Time left for user;
%u_actualProfileName% - Profile Name;
%u_actualProfileStart% - Profile start date;
%u_actualProfileEnd% - Profile end date;
%u_actualProfileLeft% - Time left for profile validity;
%u_actualRateLim% - Rate-Limit;
%u_moneyPaid% - Money paid by user;
%u_moneyUsed% - Money used by user;
%u_moneyleft% - Money left for user;
u_tillTime - Timestamp for active profile, when all profiles are exprired
u_timeLeft - sum of left time, when user does not active profile

do you mean I will use this attributes instead of $(username), $(uptime) …etc

or

What !!


Can you please modify the code and make it ready here for people to use it

yes

you can use any of these

remember we don’t have user manager. Just we want to call user’s information from statistics option associated with each user.

Not working !! we have to put dollar sign before any attribute !

if you are using ros 5.x

then it bit changed, you may need to remove "% "or “_” sign or manipulate it

this is for 3.x

I have 5.21

But must you install user-manager or not to use this attributes

I configured user-manger but ou script is not working.

There is nothing in programing like (%u_username%)… this is wrong. I don’t think at all we can use any sing other than $