4

What's the best way to get an ETH address from a website form submission (php) passed to a smart contract in order that the smart contract can send some new minted Tokens to the ETH address collected in the php form?

The user submitting the ETH address on the website does not have any ETH so we will have to pay for the Gas for any transactions.

The user's ETH address submitted on the php form is different to the msg.sender address (us).

Have been considering using PHP with: https://github.com/digitaldonkey/ethereum-php

But is there an easier approach? Thank you

  • You try it using Web3.js API? or this is not good solution for you ? – Gawey Jul 11 '17 at 12:43
  • Tks for pointer. Am solidity newbie so just feeling around in dark. Reading about Web3.js API now. Tks – POW Jul 11 '17 at 19:32
0

digitaldonkey/ethereum-php does not support signing transactions, because it would require to create a wallet in PHP and host the users private keys.

Web3p provides web3p/ethereum-wallet, but it is rather a wish than software ready to use by now (actually there isn't any code ;) ).

You might consider setting up a service based architecture and use other programming languages to create a wallet service for your key hosting and signing TX.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.