Show tx.origin.

pull/1/head
chriseth 9 years ago
parent fd4a93ad87
commit 3f7274c1d8
  1. 6
      index.html

@ -262,9 +262,8 @@ input[readonly] {
<h1>Solidity realtime<br/>compiler and runtime</h1> <h1>Solidity realtime<br/>compiler and runtime</h1>
<div class="info"> <div class="info">
<p>Version: <span id="version">(loading)</span><br/> <p>Version: <span id="version">(loading)</span><br/>
Execution environment does not connect to any node, everyhing is in-memory only.<br/> Execution environment does not connect to any node, everyhing is local and in memory only.<br/>
<strong>Note:</strong> If Chrome/Chromium reports &quot;Uncaught JavaScript Exception&quot;, <code>tx.origin = <span id="txorigin"/></code></p>
enable the debug console (Ctrl+Shift+i) and reload.</p>
</div> </div>
<div id="optimizeBox"> <div id="optimizeBox">
<input id="editorWrap" type="checkbox"><label for="editorWrap">Text Wrap</label> <input id="editorWrap" type="checkbox"><label for="editorWrap">Text Wrap</label>
@ -576,6 +575,7 @@ input[readonly] {
var secretKey = '3cd7232cd6f3fc66a57a6bedc1a8ed6c228fff0a327e169c2bcc5e869ed49511' var secretKey = '3cd7232cd6f3fc66a57a6bedc1a8ed6c228fff0a327e169c2bcc5e869ed49511'
var publicKey = '0406cc661590d48ee972944b35ad13ff03c7876eae3fd191e8a2f77311b0a3c6613407b5005e63d7d8d76b89d5f900cde691497688bb281e07a5052ff61edebdc0' var publicKey = '0406cc661590d48ee972944b35ad13ff03c7876eae3fd191e8a2f77311b0a3c6613407b5005e63d7d8d76b89d5f900cde691497688bb281e07a5052ff61edebdc0'
var address = ethUtil.pubToAddress(new Buffer(publicKey, 'hex')); var address = ethUtil.pubToAddress(new Buffer(publicKey, 'hex'));
$('#txorigin').text('0x' + address.toString('hex'));
var account = new EthVm.Account(); var account = new EthVm.Account();
account.balance = 'f00000000000000001'; account.balance = 'f00000000000000001';
var nonce = 0; var nonce = 0;

Loading…
Cancel
Save