web3p / web3.php

A php interface for interacting with the Ethereum blockchain and ecosystem. Native ABI parsing and smart contract interactions.
MIT License
1.16k stars 543 forks source link

Generates an account object with private key and public key #98

Open oom-patchara opened 6 years ago

oom-patchara commented 6 years ago

Can anyone show me how to create an account and get private key and public key in return with this web3 php library? as you can do this with original web3.js version eg. web3.eth.accounts.create([entropy]); see here https://web3js.readthedocs.io/en/1.0/web3-eth-accounts.html?highlight=web3.eth.accounts.create

Thanks

kamran-jabbar commented 5 years ago

@oom-patchara Did you get some information on the above issue as when I tried to use PHP version that returns only address?

phpemobxdev commented 5 years ago

@kamran-jabbar can you please share your php code ?

kamran-jabbar commented 5 years ago

@phpemobxdev sorry about that as I missed the PHP code, unable to get the solution in PHP so I just implemented NodeJS API endpoint and get the public key and private key from there in PHP

beardhero commented 5 years ago

I would like to be able to do this as well, will have to switch to js myself for now too.

kamran-jabbar commented 5 years ago

@beardhero yes, you have to use JS as PHP is not giving that much information with web3.