PHP code example of aoeng / laravel-web3

1. Go to this page and download the library: Download aoeng/laravel-web3 library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

aoeng / laravel-web3 example snippets



Web3::getTransactionByHash('0x54c5595bbf06ca67e45a36eb19119f7fe783539594d3c882e2e1904bb416d390')

Eth::at('0x7efB8b4d6eEC79529308a496D4A2260079ad3093')->getBalance('0xa8B42dD6efE5967659c87bFBaD5A30cC1f6fD8E5')

Contract::to($contractAddress)->at($address1, $privateKey1)->send('transfer', ['0x72f3Fe55D9A05edfD380477F16c4c997d6fEAc1F', 11])

// .... 其他的自行摸索