This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.
For more information, see this announcement post . Click the X in the top right-corner of this box to dismiss this message.
Old posts that have not been replied to for several years.
s
sege
Post
by sege » Wed Mar 20, 2002 7:52 pm
I'd like a funktion to see how long time a users has been connected to the server. The only functions I've found is to check how long users been in a channel.
Is that possible? If; how do I do?
Thanks!
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Wed Mar 20, 2002 8:58 pm
capture it from the reply from a whois (numeric 317). note that the whois has to be executed on the server they are actually on to return a 317 (ie WHOIS $nick $nick)
s
sege
Post
by sege » Thu Mar 21, 2002 4:56 am
Hmm, but then I get the signon-time in a not so very nice format, don't I? I get it in text.
What i want to do is to show how many days, hours, minutes a user been online...
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Thu Mar 21, 2002 6:06 pm
no, you get a 32bit integer from 317, the number of seconds since 0000 hours, jan 1 1970 (ie, standard unix time format), which you can mathematically manipulate into any format you like
s
sege
Post
by sege » Fri Mar 22, 2002 6:03 am
Hmm, oki, i'll play with that and see what I can do. Thanks!
BTW, where can I find info about the different raw-types?
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Fri Mar 22, 2002 7:56 am
rfc1459
s
sege
Post
by sege » Fri Mar 22, 2002 9:46 am
317 RPL_WHOISIDLE
"<nick> <integer> :seconds idle"
Hmm, how do I get online-time from this?
Coudl you give me a short example or something?
stdragon
Owner
Posts: 959 Joined: Sun Sep 23, 2001 8:00 pm
Contact:
Post
by stdragon » Fri Mar 22, 2002 10:11 am
RFC1459 is very old and most servers have all sorts of extensions to it. Try telnetting to your irc server and looking for yourself what information is contained in the 317 reply.
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Fri Mar 22, 2002 2:47 pm
yah, sorry, i shoulda checked it myself before pointing it to ya. current implementation is this
317 RPL_WHOISIDLE
"<nick> <integer> <integer> :seconds idle, signon time"
egghead
Master
Posts: 481 Joined: Mon Oct 29, 2001 8:00 pm
Contact:
Post
by egghead » Fri Mar 22, 2002 2:58 pm
On 2002-03-22 11:47, Petersen wrote:
[snip]
current implementation is this
317 RPL_WHOISIDLE
"<nick> <integer> <integer> :seconds idle, signon time"
... on most servers
/me points at irc.stealth.net...
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Fri Mar 22, 2002 6:14 pm
stealth still follows rfc 317
egghead
Master
Posts: 481 Joined: Mon Oct 29, 2001 8:00 pm
Contact:
Post
by egghead » Fri Mar 22, 2002 7:16 pm
On 2002-03-22 15:14, Petersen wrote:
stealth still follows rfc 317
March 20, 1972... Jon Postel... wow
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Fri Mar 22, 2002 7:41 pm
bah, you know what i mean.
/me sulks
s
sege
Post
by sege » Sun Mar 24, 2002 8:37 am
It's working now, thanks for all help.