1

Are there any ways to read the html from another website using javascript? In java you can just do this:

URL url = URL("https://google.com")
Scanner scanner = new Scanner(url.openStream())

and then save it to a string by doing this:

String html = ""
while(scanner.hasNext()) html += scanner.nextLine() + "\n"

but i haven't found any easy ways to do this in (plain) javascript. Are there even any? I've tried the iframe trick, but a lot of pages block it these days, including google drive, which is the page i want to get the html from.

Kris10an
  • 548
  • 3
  • 23

0 Answers0