Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening a file

Status
Not open for further replies.

disord3r

Programmer
Apr 12, 2002
189
US
I did some quick keyword searches but was unable to turn up the correct method for this, so here goes...

I need my ASP script to connect to a remote URL, grab a file, and save it locally. This seems like it should be pretty easy, but since it's happening needs to occur over HTTP, my searches weren't turning up any results. How would I go about doing this?

Also, it's possible that this remote file might be an image. If so, I would want to do some simple manipulation (check file size/dimensions, possibly resize and/or reduce colors/quality, etc). What methods/properties exist for doing such manipulations in ASP?
 
xmlhttp is a function that can do this. see here for ex,
but note that there are limitation due to a desire to limit the ability of hackers to grab any file they want by using this.

Bastien

Any one have a techie job in Toronto, I need to work...being laid off sucks!
 
Beauty. That bit of code seems to do the trick, as far as retrieving the file.

As for manipulation in the event of the remote file being an image: is there anything built-in that I can use, or do I have to find add-on components for this?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top