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.

Looking for a script to.....

Old posts that have not been replied to for several years.
Locked
R
Rob
Voice
Posts: 25
Joined: Thu Aug 01, 2002 1:21 pm

Looking for a script to.....

Post by Rob »

as said above to take track of the amount of users that joins and parts then writes it straight either to a flat file or sql so that it can be used on a website then to tell users how many users are on the channel at the time

for example, if there were 15 users in the channel it would be displayed something like "Chat Now" (Currently 15 users)

Any help would be greatfull.
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

Code: Select all

set webfile "/home/user/public_html/inchat"
set webchan "#yourchannel"
bind time - "*" webfile:update
proc webfile:update {args} {
  global webfile webchan
  set fp [open $webfile w]
  puts $fp [lleangth [chanlist $webchan]]
  close $fp
}
s
spock
Master
Posts: 319
Joined: Thu Dec 12, 2002 8:40 pm

Post by spock »

Code: Select all

puts $fp [lleangth [chanlist $webchan]]
change lleangth llength
photon?
R
Rob
Voice
Posts: 25
Joined: Thu Aug 01, 2002 1:21 pm

Post by Rob »

Many thanks for that guys.
R
Rob
Voice
Posts: 25
Joined: Thu Aug 01, 2002 1:21 pm

re

Post by Rob »

Sorry for the delay in the response to this, only just tested it. When a user joins the channel it updates the amount thats currently on, but when a user parts the channel it doesnt update the file and keep it to the higest amount of joins on that channel.

Is there any fix for this.

Cheers.
R
Rob
Voice
Posts: 25
Joined: Thu Aug 01, 2002 1:21 pm

...

Post by Rob »

:oops: no worries ive managed to make a way around this so its updated when a user parts straight.
Locked