| View previous topic :: View next topic |
| Author |
Message |
Jii92- Voice
Joined: 09 Dec 2006 Posts: 2
|
Posted: Sat Dec 09, 2006 6:07 am Post subject: ..is online/away/offline script |
|
|
Hi, im requesting script that can show someones status in irc on website.
I saw'd this, but im having a bnc so it doesn't help lot. ^^'
So it have to show that im online, and if im away it shows awaymsg that i left. And if bouncer is crashed it shows "offline".
(and don't answer "onlinestatus.org", i tried that but it doesn't work) |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Mon Dec 11, 2006 12:26 am Post subject: |
|
|
I'll work on this, gimme a few days.
This is what I have in mind so far for options:
| Code: | # Channels where we allow use:
set iwschans "#mychan #chan2 #etc"
# domain for webpage:
set iwsdom "myweb.domain.com"
# path for putting the webpage on the remote site (this directory must exist before running this script.)
set iwspath "/home/myweb/some/path"
# login name:password for the remote website
set iwslogin "mylogin:password"
# path and filename for generating/storing webpage locally
set iwsfile "/home/mybot/data/iws.html"
# user's permission flag required for adding themselves to the webstats page
set iwsuserperm "f|f"
# admin permission for adding/deleting other users from the webstats page
set iwsadminperm "n|n"
# update interval - if set to 0, immediately update webpage whenever any user's status changes, otherwise set this
# to the number of minutes to wait between updating and uploading a new status page.
set iwsupdate 0 |
Any other ideas? |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Mon Dec 11, 2006 12:34 am Post subject: |
|
|
| Ohh I should mention, I pretty much despise html so the actual html will be minimal. I'll put in a config option for a header, and will just use normal fonts/colors elsewhere. If anyone has ideas for adding html formatting or css sheets, that would be nice =) |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Mon Dec 11, 2006 5:45 am Post subject: |
|
|
I'd probably do something similar to what bwbar does..
Just output an image/unformatted textfile, and let webpages include it using SSI-includes, php, cgi, perl, etc.
Does depend on such features being implemented on the web-server, but on the other hand makes it very flexible for the user to implement.
Maybe include a couple of examples on how to include it in a webpage with various methods? _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Mon Dec 11, 2006 2:49 pm Post subject: |
|
|
Err, you lost me on that nml <grin>
This is the html template I'm planning to use:
| Code: |
# html format:
# <html><head><title> $iwshead </head></title>
# <h1><center> $iwshead </center></h1>
# <br><p>
# <ul>
# <li> $line </li>
# <li> $line </li>
# </ul>
# <h6><center> Eggdrop IRC WebStatus TCL Script - Copyright C.Leonhardt 2006 </center></h6>
# </html>
|
The format for the $line's will be something like:
$nick ($handle - $uhost) - Status: $time away ($awaymsg)
$nick ($handle - $uhost) - Status: $time Online
$nick ($handle - $uhost) - Status: $time Offline ($quitmsg) |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Mon Dec 11, 2006 4:37 pm Post subject: |
|
|
Hehe, I'll try to clarify :p
My suggestion would be to skip any and all html-coding/formatting, and just output some plain text saying "$nick!$uhost ($handle): Status - $status $msg", the suggesting users create their own html-file that includes your tiny textfile
The advantage of this solution is any and all formatting information is separated from your tcl:et, making it alittle easier for the user/webdesigner to adapt the appearance of the page. Downside would be that you'd have to use a webserver with SSI, php, cgi or such enabled..
SSI (serverside includes) example:
...
<html>
<head><title>irc-status</title></head>
<body>
<p>
<!--#include virtual="irc-status.txt" -->
</p>
</body>
</html> _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Mon Dec 11, 2006 6:24 pm Post subject: |
|
|
| Gotcha, I'll make that an option, to either produce plain text, or the rudimentary html file. |
|
| Back to top |
|
 |
demond Revered One

Joined: 12 Jun 2004 Posts: 3073 Location: San Francisco, CA
|
Posted: Tue Dec 12, 2006 1:38 am Post subject: |
|
|
| rosc2112 wrote: | | Gotcha, I'll make that an option, to either produce plain text, or the rudimentary html file. |
and for server-side notification, you might want to consider now already ubiquitous WATCH command, instead of ISON (and check for WATCH support via VERSION and 005 numeric reply) _________________ connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use [code] tag when posting logs, code |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Tue Dec 12, 2006 1:49 am Post subject: |
|
|
Hmm I didn't even think of that.. I was going to just use the join/part/quit binds, and do a periodic whois to check away status (and also have an optional command to set 'away/back' manually in the script.)
# bind join
# bind part
# bind sign
# bind kick
# bind nick
There's already a config option for which channels to use the commands in, I can make the script monitor only those channels as well (or make it an optional list of channels to monitor.) So, basically, if you're not in one of those channels, you're marked "offline"
Would be helpful Jii92 would chime in here on what options they want  |
|
| Back to top |
|
 |
demond Revered One

Joined: 12 Jun 2004 Posts: 3073 Location: San Francisco, CA
|
Posted: Tue Dec 12, 2006 3:02 am Post subject: |
|
|
actually periodic WHOIS is not recommended as it's usually more severely rate-limited than ISON and a potential cause of the bot flooding itself out due to exceeded sendq; WATCH is preferable to both of these (needless to say, none will work if the user is +i and not on bot's channels)
naturally, if that guy wants channel monitoring only, the above is irrelevant _________________ connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use [code] tag when posting logs, code |
|
| Back to top |
|
 |
Jii92- Voice
Joined: 09 Dec 2006 Posts: 2
|
Posted: Thu Dec 14, 2006 10:41 am Post subject: |
|
|
Im sorry of my bad english if someone understanded me wrong.
I just want that i can put my irc status to my blog which displays my status in irc. (not everyone in one channel, only me or somebody else, if somebody understanded me wrong)
It could check my online status every 2-10 minutes, and generate html file.
(sorry if somebody understanded me wrong :| ) |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Thu Dec 14, 2006 10:44 am Post subject: |
|
|
Ohh I was just looking for ideas for features to add to the script. The main part of the script is pretty simple, so I figured I'd beef it up some and give people more options.  |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Thu Dec 21, 2006 7:39 pm Post subject: |
|
|
| Just a bump to let you know I will be working on this script, but probably not til after the new year. I have a lot going on at the moment with the holidays. |
|
| Back to top |
|
 |
|