mIRC Home    About    Download    Register    News    Help

Print Thread
#36980 18/07/03 08:25 AM
Joined: Jun 2003
Posts: 114
T
Thray Offline OP
Vogon poet
OP Offline
Vogon poet
T
Joined: Jun 2003
Posts: 114
This is going to sound suspicious probably..

Is there a DLL (or maybe a command I don't know of) that can download a file from a remote web server? For that matter, is it even possible to make such a DLL?

I am making a client for a graphical game that, if I have my way, can get updated graphics from the server.


-------------
I am the self-appointed God of needlessly complex mIRCscript.
#36981 18/07/03 08:53 AM
Joined: Dec 2002
Posts: 103
Vogon poet
Offline
Vogon poet
Joined: Dec 2002
Posts: 103
making it with mIRC? You can just use mIRC's socket support. If using C/C++ or whatever, I think you'd be using winsock

#36982 18/07/03 11:07 AM
Joined: Dec 2002
Posts: 1,321
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Dec 2002
Posts: 1,321
This post should do pretty much what you're after.


DALnet: #HelpDesk and #m[color:#FF0000]IR[color:#EEEE00]C
#36983 18/07/03 02:56 PM
Joined: Dec 2002
Posts: 2,809
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Nah you don't use Winsock, you get lazy and use Wininet which does everything for you, you just say "download the file" "store it here" and you're done smile

#36984 18/07/03 06:15 PM
Joined: Jun 2003
Posts: 114
T
Thray Offline OP
Vogon poet
OP Offline
Vogon poet
T
Joined: Jun 2003
Posts: 114
Erm, I just was under the impression there was something more difficult to file transfers than just a raw transfer of their contents. ^-^


-------------
I am the self-appointed God of needlessly complex mIRCscript.
#36985 18/07/03 06:19 PM
Joined: Dec 2002
Posts: 127
F
Vogon poet
Offline
Vogon poet
F
Joined: Dec 2002
Posts: 127
that depends on what kind of file you're transferring. a human readable (read: .txt, .mrc, .html, etc) file can be transferred simply by requesting the file from the server and writing the contents of your /sockread variable.

and even if it is a binary file (read: .exe, .com, etc), you've got /bwrite to write binary data to files.


------
deep down, i'm really superficial.
#36986 18/07/03 06:20 PM
Joined: Dec 2002
Posts: 2,809
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Well it depends on the protocol, I assume you're talking HTTP? Then for the most part, it is just sending the contents of the file.


Link Copied to Clipboard