tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

HELPER-showorigin.html (707B)


      1 <!doctype html>
      2 <html>
      3  <head>
      4    <title>Readout of .origin</title>
      5    <style type="text/css">
      6 html, body { margin: 0; padding: 0; }
      7 div { height: 100px; width: 100px; background: blue; }
      8    </style>
      9    <script type="text/javascript">
     10 window.onload = function () {
     11  var blue = document.getElementsByTagName('div')[0];
     12  blue.ondragenter = blue.ondragover = function (e) {
     13    e.preventDefault();
     14  };
     15  blue.ondrop = function (e) {
     16    e.preventDefault();
     17    if( e.dataTransfer.origin === 'null' ) {
     18      document.body.innerHTML = 'null (string)';
     19    } else {
     20      document.body.innerHTML = e.dataTransfer.origin;
     21    }
     22  };
     23 };
     24    </script>
     25  </head>
     26  <body>
     27 
     28    <div></div>
     29 
     30  </body>
     31 </html>