User Control Panel
Advertisements

HELP US, HELP YOU!

Source

 
Post new topic   Reply to topic    Bot Depot Forum Index -> Commands
View unanswered posts
Author Message
mathieu2005
Young One
Young One


Joined: 23 Dec 2004
Posts: 76

Reputation: 18.4Reputation: 18.4

PostPosted: Sat Jan 29, 2005 6:37 pm    Post subject: Reply with quote

That is the command i create
Code:
if ($msg =~/^source (.*)/){<br />$reply = get("http://www.$1.com");<br />$self->sendmsg("$reply");<br />}
if you want to write all your web url do this
Code:
if ($msg =~/^source (.*)/){<br />$reply = get("http://$1");<br />$self->sendmsg("$reply");<br />}
Enjoy it
Back to top
mat007
Almost An Agent
Almost An Agent


Joined: 12 Jan 2004
Posts: 1375

Reputation: 15.8Reputation: 15.8
votes: 2

PostPosted: Sat Jan 29, 2005 6:39 pm    Post subject: Reply with quote

It will barely one, Some sites require you send browser info etc or use cookies etc.

Plus you should realy put $1 into a proper variable.
Back to top
alienz
Almost An Agent
Almost An Agent


Joined: 22 Mar 2004
Posts: 1436
Location: Mars
Reputation: 55.7

PostPosted: Sat Jan 29, 2005 7:25 pm    Post subject: Reply with quote

Not only that, $1 is a special variable in Perl. I would change it to something else.
_________________
Check out Botworld! A dev resource for things bot.
Downloads, articles, news, fourm and more.
http://botworld.marzopolis.com
Back to top
mathieu2005
Young One
Young One


Joined: 23 Dec 2004
Posts: 76

Reputation: 18.4Reputation: 18.4

PostPosted: Sat Jan 29, 2005 11:38 pm    Post subject: Reply with quote

like what
Back to top
Mojave
Almost An Agent
Almost An Agent


Joined: 01 Nov 2003
Posts: 1434

Reputation: 66.4

PostPosted: Sun Jan 30, 2005 12:45 am    Post subject: Reply with quote

Why can't you think of something as simple as a variable name for yourself? I would call it $icantthinkofanameforthismyselfsoiaskedotherpeopletonameifforme. I know that's a little long, but it best describes the variable's function.
Back to top
Xyem
Young One
Young One


Joined: 03 Jan 2005
Posts: 54

Reputation: 17.4Reputation: 17.4

PostPosted: Sun Jan 30, 2005 12:50 am    Post subject: Reply with quote

*applauds Mojave* Laughing

You made a typing mistake though! Just noticed... you put

...letonameifforme

Should be

...letonameitforme

:ph34r:
Back to top
..::BIGmouth( )::..
God Like
God Like


Joined: 05 Feb 2004
Posts: 801

Reputation: 44.1Reputation: 44.1Reputation: 44.1Reputation: 44.1

PostPosted: Sun Jan 30, 2005 12:50 am    Post subject: Reply with quote

Oh my gosh, that is soo Amazing! (a) Razz *cough's*
- No really, its a good 'first' command.
Back to top
Mojave
Almost An Agent
Almost An Agent


Joined: 01 Nov 2003
Posts: 1434

Reputation: 66.4

PostPosted: Sun Jan 30, 2005 2:00 am    Post subject: Reply with quote

Oops, so I can't spell the word it, haha. Razz

Bigmouth, you think it's a good command or are you joking? Anyway, this command gets the source of a url and sends it to you. Most pages I encounter are hundreds or thousands of lines and at least 10k bytes. Do you really want all of that sent to you via IM? That would hurt!

It would be a good command if it saved the source to a specified file or directory. Or if it downloaded the entire contents of the page, source and images to a directory. But that would make it a good command for the owner of the bot only (or whoever is hosting the bot).

But mostly, I just want this guy to think! At the very least, he could think of his own variable names.
Back to top
..::BIGmouth( )::..
God Like
God Like


Joined: 05 Feb 2004
Posts: 801

Reputation: 44.1Reputation: 44.1Reputation: 44.1Reputation: 44.1

PostPosted: Sun Jan 30, 2005 2:37 am    Post subject: Reply with quote

lol, I was being sarcastic. Razz
Anyhow, since the source isn't gunna change, It'll be cooler if he just added cache, soo users are actually instrested in it this 'little' post. Wink (Good o'l LWP::Usergent got 1337 and made one, sooo... here's a script you can play around with):

Code:
#Hash out the system stuff after you run it once.;-)<br />system("ppm install  LWP::UserAgent::WithCache"); <br /># Btw, Don't even know if the system would work. too lazy to try but I think it would.;-)<br /><br />use LWP::UserAgent::WithCache;<br /><br />    $msg = $1;<br />my $Expire = '600';<br />my %cache_opt = ( 'namespace' => 'lwp-cache', <br />                   'cache_root' => "./Data/Cache", <br />                   'default_expires_in' => $Expire );<br /><br />$ua = LWP::UserAgent::WithCache->new(\%cache_opt, agent => 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)');<br /><br />#thanks mojave for this var;-)<br />$icantthinkofanameforthismyselfsoiaskedotherpeopletonameifforme = $ua->get("http://$msg")->content;<br /><br />return $icantthinkofanameforthismyselfsoiaskedotherpeopletonameifforme;


Btw. I recommend this for most internet commands people post in bot-depot, unless it like some random thingy.
Back to top
Addict
Not Yet a God
Not Yet a God


Joined: 21 Jan 2004
Posts: 473

Reputation: 34.4Reputation: 34.4Reputation: 34.4

PostPosted: Sun Jan 30, 2005 3:08 am    Post subject: Reply with quote

wow that is l337ness mathieu2005 and biggie what are you thinking!? Razz
Back to top
..::BIGmouth( )::..
God Like
God Like


Joined: 05 Feb 2004
Posts: 801

Reputation: 44.1Reputation: 44.1Reputation: 44.1Reputation: 44.1

PostPosted: Sun Jan 30, 2005 3:15 am    Post subject: Reply with quote

*Cries sorry* - *Doesn't post for another couple of months*
lmao, anyways no more comedian stuff, back to the topic - this command is very very, very - bad for your botty cause it'll put your botty to sleep for a couple of seconds while querying and can be abused easily soo (Like I can easily make a spam bot open a socket with your bot and type !source randompage.com every second), Anyhow I recommend adding a timer for each user (like 3 mins).
Back to top
Siebe
God Like
God Like


Joined: 06 Jan 2004
Posts: 562
Location: Netherlands
Reputation: 39.8Reputation: 39.8Reputation: 39.8Reputation: 39.8

PostPosted: Sun Jan 30, 2005 3:45 am    Post subject: Reply with quote

Even better yet, I'll let it download an ISO! Wink
Back to top
mathieu2005
Young One
Young One


Joined: 23 Dec 2004
Posts: 76

Reputation: 18.4Reputation: 18.4

PostPosted: Fri Feb 25, 2005 2:18 am    Post subject: Reply with quote

what is a iso
Back to top
Cer
Upgraded Agent
Upgraded Agent


Joined: 03 Feb 2004
Posts: 3776
Location: Michigan
Reputation: 146.9
votes: 4

PostPosted: Fri Feb 25, 2005 12:50 pm    Post subject: Reply with quote

QUOTE(mathieu2005 @ Feb 24 2005, 09:18 PM)
what is a iso

An ISO is a type of archive file, they tend to be really large (i.e. you might find a download of "Microsoft Office 2003 Professional.iso").

Unless they were not referring to the file extension, ISO, than I have no idea what they are talking about. :rolleyes:

_________________
Current Site (2008) http://www.cuvou.com/
Back to top
draget
Not Yet a God
Not Yet a God


Joined: 29 Dec 2004
Posts: 367
Location: Australia
Reputation: 32.2Reputation: 32.2Reputation: 32.2

PostPosted: Fri Feb 25, 2005 2:38 pm    Post subject: Reply with quote

ISO's are generally CD images.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Bot Depot Forum Index -> Commands 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