本文共 354 字,大约阅读时间需要 1 分钟。
个人博客原文
web3js调用获取当前账户
记得加
, from: web3.eth.accounts[0]}
VotingContract.deployed().then(function(instance){ instance.giveRightToVote(address,{gas: 140000, from: web3.eth.accounts[0]}).then(function(result){ $("#msg2").html("已授权
") }) }).catch(function(err){ console.error("ERROR! " + err.message) })
公众号每周推送区块链技术文章
个人踩坑日记
转载地址:http://hrqnn.baihongyu.com/