wood burning stoves*
The moose likes Other JSE/JEE APIs and the fly likes how to get the download link Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "how to get the download link" Watch "how to get the download link" New topic
Author

how to get the download link

Arifiadi Patahuddin
Greenhorn

Joined: Nov 24, 2011
Posts: 3
hi,

Please help me to make a java program

i have problem
for example:
I have a download page with the URL name http://www.filestube.com/e745ba6956eca87503e9/go.html

that page has the download link ..
how to parse the page using java to get the download link ...
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19649
    
  18

Welcome to the Ranch!

You will need to parse the HTML to retrieve the right URL. Just look for a good HTML parser, there are many around. You may need to use an abstraction layer for retrieving the HTML to handle cookies, logins etc properly. Check out JWebUnit and Apache Commons HttpClient.

Be warned though that in automatic downloads of sites you may violate the sites' terms and conditions. This may get you banned from the site (possibly on IP basis) or worse. I'm pretty sure that the site you gave does not allow it.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Arifiadi Patahuddin
Greenhorn

Joined: Nov 24, 2011
Posts: 3
Rob Spoor wrote:Welcome to the Ranch!

You will need to parse the HTML to retrieve the right URL. Just look for a good HTML parser, there are many around. You may need to use an abstraction layer for retrieving the HTML to handle cookies, logins etc properly. Check out JWebUnit and Apache Commons HttpClient.

Be warned though that in automatic downloads of sites you may violate the sites' terms and conditions. This may get you banned from the site (possibly on IP basis) or worse. I'm pretty sure that the site you gave does not allow it.


thanks for attention
can you give me sample code to get the download link without having to click the download button..
i don't know how to parse java script
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to get the download link
 
Similar Threads
Eclipse source code
Unwanted browser window
how to catch redirect link on java ?
unable to download the source code or open source project
my overlay box works in Firefox, but fails in IE8