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.

IRC Online Status Indicator

Old posts that have not been replied to for several years.
Locked
User avatar
Thunderdome
Op
Posts: 187
Joined: Tue Mar 15, 2005 4:42 pm

IRC Online Status Indicator

Post by Thunderdome »

hello!
I dunno if you guys know www.onlinestatus.org
Well, the IRC status indicator is crap and won't work on most networks.
I want to do something similar...
So, when certain nick is online, an image is shown.
When it is offline, other image is shown.

Or something perhaps more meticulous, like when a user is online, it shows the nick currently in use by that user. When it's offline it shows "offline".

The ideia is to link from a webpage to a particular image the bot makes/selects/renames....
The second case must be in php right? Can it be done with javascript?

I think this sounds simple, but I have no ideia of how to do this in tcl.
Anyone?
thanks! :D
User avatar
Thunderdome
Op
Posts: 187
Joined: Tue Mar 15, 2005 4:42 pm

Post by Thunderdome »

anyone with any ideias? :\
d
deadite66
Halfop
Posts: 74
Joined: Mon May 30, 2005 2:49 am
Location: Great Yarmouth, UK

Post by deadite66 »

is this the kind of thing you want http://www.egghelp.org/cgi-bin/tcl_arch ... ad&id=1061

Write Channel Nicklist 2 File
Will write all the current users on your channel to a txt file. It keeps users status such as opped and voiced users. There is an example irc_stats.php file included that will list the users from the stored nicklist.txt file and will also count how many are online.
User avatar
Thunderdome
Op
Posts: 187
Joined: Tue Mar 15, 2005 4:42 pm

Post by Thunderdome »

Yes, I've seen that... but the problem is making a javascript to put just one of the nicknames in a part of the site as online or offline.
Like in that onlinestatus.org site...
Have an ideia how to do it?
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

I dont see any javascript used on onlinestatus.org for displaying the status. its just a plain picture tunneled through a script, which could be php, but does not neccessary to be so. Can be almost any other scripting language or libary/plugin that suppports file reading and binary data output.
The script probably is build in this structure:
- reading the status request from the URL string
- checking the status against the database (which can also be a text file)
- opening a image file representing the users status and dump it to the user agent

I would not recommend JavaScript, since it would need to read the whole datebase. If you do this you should ensure the datebase wont exceed a limit, so the file trasnfer size doesnt go above a few kilobytes (if compression is active the actuall size might be bigger).

PS: even the official web status from ICQ works that way :D. the only diffrent is, that its not using a script but a compiled libary :D
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
User avatar
Thunderdome
Op
Posts: 187
Joined: Tue Mar 15, 2005 4:42 pm

Post by Thunderdome »

I said javascript because I don't use php in the page where I want the online status.

The ideia is to get just the online status from 1 single nick from one channel whcih at most gets 10 people.
I can use that script to create a filelist of all #channel users, but I dunno how to use javascript to reads the file and select a user, and then make it so an image or something is added if the user is found. In javascript this is way over what I can do.

So I was wondering if there is a way to do this in tcl. The bot sees a nick and then published some .js file that contains info to show up some picture, or another to show another pictrue in case that nick is not there. get my ideia?
Locked