title: Access CURRENT src in embed object HTML
body: <p>I have created an embed object in HTML and this code in Javascript:</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>function mainLoop() {
    var browser = document.getElementById("browser");
    console.log(browser.src);
  }
  
  //call main loop
  setInterval(mainLoop, 1000);</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;embed src="https://en.wikipedia.org/wiki/Main_Page" id=browser&gt;</code></pre>
  </div>
  </div>
  </p>
  <p>When I run the webpage, the console constantly prints <code>&quot;https://en.wikipedia.org/wiki/Main_Page&quot;</code>, which is what is expected. However, when I click on a link inside the embed HTML to change the webpage inside the embed HTML, the console continues to print <code>&quot;https://en.wikipedia.org/wiki/Main_Page&quot;</code>.</p>
  <p>How do I access the current URL of the content inside of the embed HTML?</p>
  <p>(I cannot use <code>browser.contentWindow</code> because of a Security Error)</p>