How can I download the code from a web page from an application made in java?

0

The question is the following, I would like to download the code from a web page from an application made in JAVA, the problem arises in that when I enter the url I want to download, instead of downloading that page corresponding to the URL, I Download the LOGIN page, which I do not want. They have some idea that I can implement to do this.

    
asked by DaNn Jimenez 30.05.2018 в 21:45
source

2 answers

0

There is already an answer to this question, although it is in English. link

The previous answer implements sockets (SSL in the specific case of the provided link, given that the web page is consulted under the HTTPS protocol) to read pages as data streams

    
answered by 30.05.2018 в 22:13
0

To download (and process) HTML pages I use JSoup . Now , if you say that you have done something and you are downloading a login page it means that the URL that you are going through is secured and, therefore, from your application, you will have to perform the login, obtain the , probably, session token that will be generated by the server and include it in the requests that you make later, but that already completely leaves the question you have raised.

    
answered by 30.05.2018 в 22:23