diff options
author | Taylor Gerring <taylor.gerring@gmail.com> | 2015-02-11 18:40:12 +0800 |
---|---|---|
committer | Taylor Gerring <taylor.gerring@gmail.com> | 2015-02-11 18:40:12 +0800 |
commit | cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007 (patch) | |
tree | ab28c518bd1b78f6b8ac8b241951ad161cb268a9 /cmd/mist/assets/html/home.html | |
parent | 21fd31dad8bc6e0291ca405314b516670333c707 (diff) | |
parent | c6af5f0a275608ea6c797ef826e6090885f24eac (diff) | |
download | go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar.gz go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar.bz2 go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar.lz go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar.xz go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.tar.zst go-tangerine-cfddb7f3cd3b8cecb1e59412ce4db5769f6c8007.zip |
Merge branch 'develop' into jsonrpc
Conflicts:
rpc/ws/server.go
Diffstat (limited to 'cmd/mist/assets/html/home.html')
-rw-r--r-- | cmd/mist/assets/html/home.html | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/cmd/mist/assets/html/home.html b/cmd/mist/assets/html/home.html new file mode 100644 index 000000000..dc96cc754 --- /dev/null +++ b/cmd/mist/assets/html/home.html @@ -0,0 +1,83 @@ +<!doctype> +<html> +<head> +<title>Ethereum</title> +<script type="text/javascript" src="../ext/bignumber.min.js"></script> +<script type="text/javascript" src="../ext/ethereum.js/dist/ethereum.js"></script> +<style type="text/css"> + body { + font-family: Helvetica; + } + div.logo { + width: 192px; + margin: 40px auto; + } +</style> +</head> +<body> + <div class="logo"><img src="logo.png"></img></div> + <h1>Info</h1> + + <table width="100%"> + <tr> + <td>Block number</td> + <td id="number"></td> + </tr> + + <tr> + <td>Peer count</td> + <td id="peer_count"></td> + </tr> + + <tr> + <td>Accounts</td> + <td id="accounts"></td> + </tr> + + <tr> + <td>Gas price</td> + <td id="gas_price"></td> + </tr> + + <tr> + <td>Mining</td> + <td id="mining"></td> + </tr> + + <tr> + <td>Listening</td> + <td id="listening"></td> + </tr> + + <tr> + <td>Coinbase</td> + <td id="coinbase"></td> + </tr> + </table> +</body> + +<script type="text/javascript"> + var web3 = require('web3'); + var eth = web3.eth; + + web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8545')); + + document.querySelector("#number").innerHTML = eth.number; + document.querySelector("#coinbase").innerHTML = eth.coinbase + document.querySelector("#peer_count").innerHTML = eth.peerCount; + document.querySelector("#accounts").innerHTML = eth.accounts; + document.querySelector("#gas_price").innerHTML = eth.gasPrice; + document.querySelector("#mining").innerHTML = eth.mining; + document.querySelector("#listening").innerHTML = eth.listening; + + eth.watch('pending').changed(function() { + console.log("pending changed"); + }); + eth.watch('chain').changed(function() { + document.querySelector("#number").innerHTML = eth.number; + }); + +</script> + +</html> + |