User Control Panel
Advertisements

HELP US, HELP YOU!

Save Stats number

 
Post new topic   Reply to topic    Bot Depot Forum Index -> Code Help
View unanswered posts
Author Message
Gavin
God Like
God Like


Joined: 15 Mar 2004
Posts: 661
Location: Manchester, UK
Reputation: 36.2Reputation: 36.2Reputation: 36.2Reputation: 36.2

PostPosted: Wed Apr 14, 2004 3:15 pm    Post subject: Reply with quote

I use the stats command


if ($msg =~ /^stats/) {
my $allow = $msn->getlist('AL');
my $blocked = $msn->getlist('BL');
&send($self, "Statistics:\n\nUsers: $allow\nBlocked Users: $blocked\n", "$username");
}

is there any code so that it saves the number of allowed users into a folder?

_________________
MSN: gavin [at] gavinbrittain [dot] co [dot] uk
E-Portfolio: www.gavinbrittain.co.uk (New version comming soon)
Back to top
JoeX
Agent
Agent


Joined: 02 Jan 2004
Posts: 2153

Reputation: 72.7

PostPosted: Wed Apr 14, 2004 3:19 pm    Post subject: Reply with quote

QUOTE(Gavin @ Apr 14 2004, 07:15 AM)
I use the stats command


if ($msg =~ /^stats/) {
my $allow = $msn->getlist('AL');
my $blocked = $msn->getlist('BL');
&send($self, "Statistics:\n\nUsers: $allow\nBlocked Users: $blocked\n", "$username");
}

is there any code so that it saves the number of allowed users into a folder?

Hmm try this:
Code:
   open(FILE, ">>./Lists/Allowed");<br />     print FILE "$allowed\n";<br />  close(FILE);


You need this as the 'my' bit
Code:
my $allow = $msn->getlist('AL');

_________________
Heroes NBC
Back to top
Gavin
God Like
God Like


Joined: 15 Mar 2004
Posts: 661
Location: Manchester, UK
Reputation: 36.2Reputation: 36.2Reputation: 36.2Reputation: 36.2

PostPosted: Wed Apr 14, 2004 3:21 pm    Post subject: Reply with quote

were do i put the

open(FILE, ">>./Lists/Allowed");
print FILE "$allowed\n";
close(FILE);

im a n00b and i dnt no how to put codes together Sad

_________________
MSN: gavin [at] gavinbrittain [dot] co [dot] uk
E-Portfolio: www.gavinbrittain.co.uk (New version comming soon)
Back to top
Calum
Not Yet a God
Not Yet a God


Joined: 21 Feb 2004
Posts: 373
Location: england
Reputation: 34.7Reputation: 34.7Reputation: 34.7

PostPosted: Wed Apr 14, 2004 3:43 pm    Post subject: Reply with quote

Code:
 if ($msg =~ /^stats/) {<br /> my $allow = $msn->getlist('AL');<br />   my $blocked = $msn->getlist('BL');<br />    &send($self, "Statistics:\n\nUsers: $allow\nBlocked Users: $blocked\n", "$username");<br />      open(FILE, ">>./Lists/Allowed");<br />    print FILE "$allowed\n";<br /> close(FILE);<br />}<br /><br />


and next time use the code button <_<
Back to top
Stephen
Senior Member
Senior Member


Joined: 03 Dec 2003
Posts: 159

Reputation: 32.8Reputation: 32.8Reputation: 32.8

PostPosted: Thu Apr 15, 2004 4:12 am    Post subject: Reply with quote

That coding sucks. You never even read it!

Code:
if ($msg eq "stats") {<br />  my $allow = $msn->getlist('AL');<br />  my $blocked = $msn->getlist('BL');<br />   &send($self, "Statistics:\n\nUsers: $allow\nBlocked Users: $blocked\n", "$username");<br />   open(FILE, ">>./Lists/Allowed.txt");<br />   print FILE "$allow\n";<br />close(FILE);<br />}


Make a folder called Lists in the main directory.

Smile
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Bot Depot Forum Index -> Code Help All times are GMT
Page 1 of 1

 



Protected by phpBB Security phpBB-TweakS
phpBB Security Has Blocked 9 Exploit Attempts.
Antispam Captcha Mod by phpbb-security.com
Powered by phpBB © 2001, 2005 phpBB Group