Open robinkbr opened 1 year ago
`protected $web3;
public function __construct()
{
//与合约交互需要设置超时
$this->web3 = new Web3(new HttpProvider(new HttpRequestManager('http://127.0.0.1:8545', 30)));
}
public function createAccount() { $this->web3->personal->newAccount('your_password', function ($err, $account) { if ($err !== null) { // do something return; } echo $account; }); } `
`protected $web3;
public function __construct() { //与合约交互需要设置超时 $this->web3 = new Web3(new HttpProvider(new HttpRequestManager('http://127.0.0.1:8545', 30))); }
public function createAccount() { $this->web3->personal->newAccount('your_password', function ($err, $account) { if ($err !== null) { // do something return; } echo $account; }); } `
Whats is HttpRequestManager
?
Do you know how to make a wallet in php?