Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > Java Basics
|
Java Basics General beginning Java language questions that don't fit in one of the more specific forums. Please specify what version.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 9th, 2006, 01:16 AM
Authorized User
 
Join Date: Nov 2004
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to pandjie
Default downloading image from website

if we have a URL, such as http://website.com/image.jpg, and we want to make a java program which can download that image, how can we do it ? what library can we use ?

Thanks.

 
Old December 11th, 2006, 10:39 PM
Authorized User
 
Join Date: Nov 2004
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to pandjie
Default

it's simple... just use URLConnection class, and get content as input stream, and then save it to a file....

that's it !!!






Similar Threads
Thread Thread Starter Forum Replies Last Post
Downloading files from website to user's PC LenexaKS ASP.NET 2.0 Professional 15 February 16th, 2008 01:20 PM
How to restrict the size of an image in a website venup ASP.NET Espanol 0 December 2nd, 2006 01:43 AM
Downloading a image file from Oracle on to JSP Pag ashwinmittal Pro JSP 1 November 25th, 2004 09:37 AM
deny downloading image files. jojys Javascript How-To 1 October 19th, 2004 03:17 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.