Page source not the same : getInputStream() vs Ctrl+U
I'm using a program to access the page source of a website. I've noticed that the content is not the same as when I do it manually using Ctrl+U in the browser. Some important data are missing in the page source when I use the program, which relies on the getInputStream() method. Do you know why, and how can I fix it?
Many thanks for helping me!
String site = "http://magasin.iga.net/Browse/All.aspx?os=1";
URL url = new URL(site);
URLConnection connection = url.openConnection();
Scanner in = new Scanner(connection.getInputStream());
line = in.nextLine();
(print line to a file)