Community discussions

MikroTik App
 
irDi
just joined
Topic Author
Posts: 3
Joined: Wed Oct 19, 2011 2:07 pm

change timer status hotspot mikrotik

Sat Apr 14, 2012 10:53 pm

Hi masters,
I wanna change the timer status hotspot mikrotik,
the default is, example: $(session-time-left)=> "2d3h23m45s".
I wanted to change like this "2day+ 3hour 23minutes 45second".
any idea?
is it from mikrotik-console(scripts) or using javascript on html page?
thanks a lot
 
User avatar
perspetolis
Member Candidate
Member Candidate
Posts: 101
Joined: Tue Aug 02, 2011 9:08 pm
Location: Tehran
Contact:

Re: change timer status hotspot mikrotik

Sun Apr 15, 2012 8:16 pm

hi
for example,if you want to convert real time to your request,you can use from this script:

:global ts [/system clock get time]
:set ts ([:pick $ts 0 2]. "Hour" .[:pick $ts 3 5]."Minutes".[pick $ts 6 8]."Second")
:put $ts
 
irDi
just joined
Topic Author
Posts: 3
Joined: Wed Oct 19, 2011 2:07 pm

Re: change timer status hotspot mikrotik

Mon Apr 16, 2012 10:55 pm

I mean, timer hotspot status (voucher) page on client-side.
the default from mikrotik on $(session-time-left) is => "2d3h23m45s".
I wanted to change like this "2day+ 3hour 23minutes 45second".

Who is online

Users browsing this forum: Ahrefs [Bot], scoobyn8 and 23 guests