James Bachini

Transfers

  • Payable Transfers | Solidity Tips & Examples

    Payable Transfers | Solidity Tips & Examples

    Payable transfers are one of a number of ways to send ether from a Solidity smart contract to an external address. In this next example we create a fallback function so that any user can send this contract ether and it will get split between the different addresses. Full code at: https://github.com/jamesbachini/Solidity-Snippets/blob/main/contracts/PaymentDivider.sol Payable fails if…