Tutorial :Fetching webpages through https



Question:

does anyone know of a Java library to fetch webpages through https?


Solution:1

Take a look at HttpClient


Solution:2

As of 1.4, you can use boring old URL.openConnection()...


Solution:3

There is a great example of how to fetch a websites contents right in Sun's Java tutorial.

http://java.sun.com/docs/books/tutorial/networking/urls/readingURL.html

However if you want to fetch it's entire contents including scripts, images, and other goodies, you will have to parse out the links yourself and download them as well.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »