Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8"/>
- <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
- <link rel="shortcut icon" type="image/x-icon" href="/Users/Owner/Documents/icons/navy_favicon.ico"/>
- <title>Current Fleet Positions</title>
- </head>
- <body>
- <script type="module">
- const proxy = "https://proxy.corsfix.com/?";
- const targetUrl = "https://news.usni.org/category/fleet-tracker";
- const response = await fetch(proxy + targetUrl);
- const htmlText = await response.text();
- const parser = new DOMParser();
- const doc = parser.parseFromString(htmlText, 'text/html');
- const images = doc.querySelectorAll('img');
- const newImg = document.createElement('img');
- newImg.src = images[3].src;
- newImg.width = 943;
- newImg.height = 628;
- document.body.style.backgroundColor = "#a4e1e7";
- document.body.style.textAlign = "center";
- document.body.appendChild(newImg);
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment