News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

FTP HTML File Downloads

Started by Retsim_X, January 22, 2005, 09:11:52 AM

Previous topic - Next topic

Retsim_X

Hey,

how would i go about creating a download app similar to getright or mozzila etc.

i dont understand the correct api's

XORo, Retsim_X the old

pbrennick

IIRC, Iczelion posted something here, http://win32asm.cjb.net/, he also had something that allowed you to open a zip remotely and just download exactly what you want.  How cool is that!

Paul

Robert Collins

Quote from: pbrennick on January 22, 2005, 06:56:58 PM
IIRC, Iczelion posted something here, http://win32asm.cjb.net/, he also had something that allowed you to open a zip remotely and just download exactly what you want.  How cool is that!

Paul


I couldn't find that particular example but I sure found a ton-load of many very interesting samples and snippits. That is quite a site.

pbrennick

Robert,
You evidently had one eye closed because both programs are there.  Anyway I will attach them here for you.  There should be two attachments if I do this right.
Paul


[attachment deleted by admin]

Robert Collins

Quote from: pbrennick on January 23, 2005, 09:22:36 PM
Robert,
You evidently had one eye closed.......

Your're probably right. I had just gotten up from bed and didn't even have my first cup of coffee yet because the first thing I do when I awake is to fire up the PC and check for emails.

Robert Collins

I ran both of those samples but only the http one worked. When I ran the zip downloader it downloaded the zip file but after that WinZip did not show any of the files within the zip file. I did a dump of the zip file and it does appear to look like a valid zip file but never the less WinZip still shows nothing to extract. So, I went back to the URL and downloaded the same zip file using CuteFTP. This time it was exactly the same size as the one downloaded using zipdll.exe. It also looked the same in the dump editor and it was un-zippable. So, I went back to the same URL and tried using zipdll.exe again. Again, it downloaded the zip file but as before there were no files in the WinZip window to extract.

Maybe there is a problem with zipdll.exe that it doesn't store the downloaded zip file correctly. I don't know cuz I am not advanced far enough yet to determine any incorrect logic within the source.

pbrennick

Robert,
I just tested it and it worked okay for me.  This is how it works:

Start the program, and type in the following line:
http://www.pbrennick.com/AssemblyStuff/GeneSys/GeneSys.zip
Then click connect.  You will see a listing of the contents in the window below.  Click on one of the files, I chose GeneSys.asm, and then click download.  Choose where to put it and remember where.  After it is done you can close the program.  If you look where you picked to put the program it will contain a file called GeneSys.zip, but it will only contain GeneSys.asm, your choice.  That is how it works and it works fine for me.  I hope this helps you.  The other program is actually the one he asked for but I personally like zipdl.exe.

Paul

Robert Collins

Well, when I select your URL it works OK but when I select my URL it does everything as though I was selecting yours except that the end results is the way I explained above. The file does have a valid file size (because I compared it with a good download) but when I try to open it up with WinZip it is empty.

On the other hand, I uploaded your GeneSys.zip to test it. OK, when I use zipdll.exe to d/l it and pick the file it works but not with my other zip files. I know the other zip files are valid because they work when I download them using CuteFTP.

Here's the URL I am using http://futureedge.com/ChatBox.zip

Note the absense of 'www' in my URL. Could that have anything to do with it?

pbrennick

Robert,
Let me test it and I will get back to you.  I am cncerned that you can get my zip to work but not yours, though.  Anyway, I'll get back to you.
Paul

pbrennick

Rbert,
Even though zipdl.exe is able to parse the entire directory tree of this complex zip file it is unable to correctly extract any files that are not on the top level.  ChatApplet.html.txt and ChatApplet.html are the only files that will download correctly.  I feel this is a bug in Iczelion's program because if the program lists a file, it should be able to obtain it.  Sorry.  I don't think he will respond to an email, either, because life is keeping him very busy.  As you can see, his site has not been updated in a while.  Most of the stuff there will probably work with no problem, though.  Do not be discouraged by one bad experience.  I do not understand enough about zip internals to take a try at fixing it.

Paul

Robert Collins

OK, no problem and thanks alot for your investigating into this situation. I worked with zip file formats some time back so I might have to go back and search my archives for the stuff I was doing but it wasn't in assembly so I don't know if I will be able to 'see' a zip format error in the assembly version but I will 'see' what I can.