dapp-bin icon indicating copy to clipboard operation
dapp-bin copied to clipboard

chat.html is not working

Open MohamedAlaa opened this issue 8 years ago • 1 comments

I've tried to play with chat/chat.html but it's missing something.

Uncaught ReferenceError: web3 is not defined at chat.html:120

do we need to link a specific javascript file?

Thanks, Mohamed.

MohamedAlaa avatar Oct 10 '17 02:10 MohamedAlaa

$(window).load function() { web3.eth.getAccounts(function(err,accs) { if (err != null) { alert("There was an error fetching your accounts."); return; }

if (accs.length == 0) {
  alert("Couldn't get any accounts! Make sure your Ethereum client is configured correctly.");
  return;
}

accounts = accs;
account = accounts[0];

refreshBalance();

}); }

sumitsg10 avatar Jan 07 '18 14:01 sumitsg10