mIRC Home    About    Download    Register    News    Help

Print Thread
Is there a way of doing this? #55916 18/10/03 09:05 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
Does anybody know perhaps of a script, which can read and display the amount of people, which are currently in an IRC room, and place that number on a website.

Is this possible?

Re: Is there a way of doing this? #55917 18/10/03 09:10 PM
Joined: Oct 2003
Posts: 30
pleur Offline
Ameglian cow
Offline
Ameglian cow
Joined: Oct 2003
Posts: 30
yeah sure, but you should write an upload-script to update the site, and I think's that's difficult

you should better open a socket (to listening), and use that instead of the page

example: [url removed by PleuR]

Last edited by pleur; 18/10/03 09:19 PM.

------
Cheers m8!
Re: Is there a way of doing this? #55918 18/10/03 09:15 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
all I am looking for is a script that says something like:

There is 3 members on the #Santharia channel

What you should me is a little too much.


Re: Is there a way of doing this? #55919 18/10/03 09:15 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
or just

There is 3 members on the channel

Re: Is there a way of doing this? #55920 18/10/03 09:19 PM
Joined: Oct 2003
Posts: 30
pleur Offline
Ameglian cow
Offline
Ameglian cow
Joined: Oct 2003
Posts: 30
i'm sorry, I mis understood you


//echo There are $nick(#channel,0) ppl on the channel
//echo There are $nick(#channel,0,o) ops on the channel
//echo The first voice on the channel is $nick(#channel,1,v)
see /help $nick for more info


------
Cheers m8!
Re: Is there a way of doing this? #55921 18/10/03 09:21 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
but I need to have that text shown on a website.

I think I confused you....sorry

Re: Is there a way of doing this? #55922 18/10/03 09:23 PM
Joined: Oct 2003
Posts: 30
pleur Offline
Ameglian cow
Offline
Ameglian cow
Joined: Oct 2003
Posts: 30
Hehe, i see


To do that, you have to edit the page, this must be done with Sockets, and requiers some scripting skills...
But if you think you can do it, and you can access your site with FTP, you have to learn sockets and the FTP protocol to edit the page


------
Cheers m8!
Re: Is there a way of doing this? #55923 18/10/03 09:25 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
Is there a place I could learn about this stuff?

Re: Is there a way of doing this? #55924 18/10/03 09:27 PM
Joined: Oct 2003
Posts: 8
A
Aazn Offline
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
A
Joined: Oct 2003
Posts: 8
You dont seem to understand. His question is

Quote:

Does anybody know perhaps of a script, which can read and display the amount of people, which are currently in an IRC room, and place that number on a website.


Notice that he wants to post it to a WEBPAGE, not on mIRC.

He probably wants a perl script that opens a mirc socket, listens, counts the users, and disconnects. I personally cant script in perl, and I dont want to learn so I suggest that you find some perl documents. Here, I'll give you a headstart in the Research:

Perl CGI

Perl Bots

Perl stats generator

How to connect to IRC through Perl

Simple Perl Bot

There. I've done some of the legwork for you, you need to read them. I think that going to perl is the best way possible at the moment, unless your better at VB/C++.

- Aazn


( www.nnscript.de )
Re: Is there a way of doing this? #55925 18/10/03 09:29 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
I might not of been as clear as I coulda been. Just got off work and its late here

Thanks though. I will read up on the info.

Re: Is there a way of doing this? #55926 18/10/03 09:54 PM
Joined: Dec 2002
Posts: 1,922
O
Online Offline
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922
You don't have to mess up with sockets for that, there's a clean way of uploading your file through FTP to your webpage. See this tutorial for details laugh

Re: Is there a way of doing this? #55927 19/10/03 08:02 AM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
okay well I got some rest and think I am going to try this again.

What I am looking for is this:

I have a website, this website has its own channel. What I would like is some kinda Javascript or something, that will create the following text:

There is currently [color:blue]3 people on the channel.[/color]

This line of text will be found on a website, not on IRC. It will update itself when ever someone joins the room or leaves. Thus the blue number may increase to 4 when a person joins, or reduce to 2 when a person leaves.

I don't need it to be a live script, constantly changing. Just need it to look into the channel when the page is loaded, get the number of people in the channel, then report it. Doing this each time the page is reloaded.

* Gar wonders if he made himself any clearer.

Re: Is there a way of doing this? #55928 19/10/03 11:46 AM
Joined: Dec 2002
Posts: 1,922
O
Online Offline
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922
I understand what you are trying to do, and I think the best way would be running a timer that will periodically (every 5-15 mins) write the current usercount along with some HTML stuff into a file, and upload it to the website.

If you wanted to update the usercount whenever someone is viewing your page that would involve a lot of server-side programming (even running a separate clone for that, like the Online /whois service does) as well as delay that will likely annoy the visitors, and I honestly don't think it's not worth it.

Re: Is there a way of doing this? #55929 19/10/03 03:40 PM
Joined: Oct 2003
Posts: 50
T
Tsunami Offline
Babel fish
Offline
Babel fish
T
Joined: Oct 2003
Posts: 50
I think he doesn't want to run a script for mIRC to do it, but something like he said, a JavaScript thingy that will look for the usercount...

Re: Is there a way of doing this? #55930 19/10/03 04:11 PM
Joined: Oct 2003
Posts: 8
A
Aazn Offline
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
A
Joined: Oct 2003
Posts: 8
I dont think he wants mirc to do it, I think he wants PERL or JavaScript to look at the channel and say 'We have XX users in #EEE'. It would be easy doing it from mIRC, but what if his computer crashes.

He wants it to update on the website, so that he doesn't have to look at the sockets opening. It would be hard, but you can do it through perl. I know that. Perl is used for alot of chats, but PHP might work also.

I'd reccomend looking into PHP also.

- Aazn


( www.nnscript.de )
Re: Is there a way of doing this? #55931 19/10/03 06:08 PM
Joined: Dec 2002
Posts: 1,922
O
Online Offline
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922
I can't help much then crazy

It would help if somebody already published such a PHP/Perl bot with some documentation.

Re: Is there a way of doing this? #55932 19/10/03 11:13 PM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
yep, you get it now...but sadly can't help me frown

Re: Is there a way of doing this? #55933 20/10/03 05:09 AM
Joined: Jan 2003
Posts: 3,012
KingTomato Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
Unless you write a script (php, perl, etc) that connects to the server, joins ur channel, does a names lisitng and counts the users, and disconnected every time auser visits the page--its wont happen. The only other alternative is you, yourself, run a timer that sends a query to a page updating user count. Such as php could do:

www.somepage.com/users.php?count=<number>

And use sockets to connect and update the webpage via users.php


-KingTomato
Re: Is there a way of doing this? #55934 26/10/03 03:02 AM
Joined: Jul 2003
Posts: 6
A
archfiend Offline
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
A
Joined: Jul 2003
Posts: 6
As long as your channel is being indexed by SearchIRC, there is a built in feature from SearchIRC that allows you to do exactly that.

Please look at request channel stats

Last edited by archfiend; 26/10/03 03:05 AM.