mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
I'm basically trying to make my bot so that when someone types "!unbanplayer <name>", the bot will connect to an FTP server, find a file, edit it, save it, etc.

This is just an example to give you an idea of what I'm trying to do. This obviously doesn't work, and the variables don't exist, just note that it is an example!:

http://www.paste.mircscripting.info/index.php?id=2762

------------

So basically someone in IRC types "!unbanplayer <name>". Then the bot connects to an FTP server, finds a file in a directory named "<name>.txt", opens it, searches for an instance of "banned=1" and changes it to "banned=0" (this unbans a player).

Is this possible? I'm sorta new with scripting, but it sounds like I'd need to use some sockets, and I have no clue how to use them. Any support is appreciated. smile

Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
How about you start by giving the FTP address, a guest account to login temporarly then I will be more then willing to write something up :P


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
Sorry, but I don't think so.

You absolutely NEED my information, or can't I add that later?

Joined: Sep 2007
Posts: 202
F
Fjord artisan
Offline
Fjord artisan
F
Joined: Sep 2007
Posts: 202
for login and getting to a dir http://dogus.free.fr/ftprush/RushAppFTP_all.htm

for edit I guess you need to dl the file, edit it and then re-upload it

Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Originally Posted By: Joe_Dean
Sorry, but I don't think so.

You absolutely NEED my information, or can't I add that later?


Fine then I don't think so I can help sorry.


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
Originally Posted By: Lpfix5
Originally Posted By: Joe_Dean
Sorry, but I don't think so.

You absolutely NEED my information, or can't I add that later?


Fine then I don't think so I can help sorry.


Hostname: ftp.lvrcr.com
Username: test@lvrcr.com
Password: mypass123

Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
This is exactly why I didn't want to do this... Those test account details haven't been published for even a day yet, and already we have idiots uploading shit to my webspace.

I'd kindly like to ask if you could make this a bit quicker. I don't mean to sound rude and I don't want to rush you, but I can't have people uploading shit and using my space...

Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
Feel free to change your login info and give the new info to him *privately*. No one really required you to make it public.. though I question why any details should have been given in the first place.. it should definitely not have been necessary.

Anytime someone threatens to stop helping you unless you give them sensitive security information (especially passwords), you should ignore them outright. No one here should ever ask that of you.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
That's what I thought, but apparently it was essential to have a test account. I don't see how it's necessary as he could've used his own server or something, but whatever.

By the time he reads this, he probably won't help anyways. Meh, I'll keep the test account active for 24 more hours, then I'll delete it.

Joined: Dec 2007
Posts: 48
K
Kol Offline
Ameglian cow
Offline
Ameglian cow
K
Joined: Dec 2007
Posts: 48
http://forum.swiftirc.net/viewtopic.php?t=15791

The author is considered a god on our network ^^

Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
Thanks, but that's not exactly what I'm looking for.

I don't want anything downloaded to my computer, and I don't want to have to upload anything from my computer either. Basically I just want the script to search for a string in the specified file on the FTP server, then edit it & save the file.

Joined: Dec 2002
Posts: 2,962
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
There's no way to edit a file on a remote FTP server in-place. You would need to download it, edit it, and then upload it over the old file.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
Joined: May 2008
Posts: 127
J
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2008
Posts: 127
Ah, ok. Thanks wink


Link Copied to Clipboard