我想通過PHP中的比特幣地址轉移比特幣,請分享正確的鏈接。如何在PHP中將coinbase api集成到轉移bitcoine中
https://developers.coinbase.com/docs/merchants/payment-buttons
我想通過PHP中的比特幣地址轉移比特幣,請分享正確的鏈接。如何在PHP中將coinbase api集成到轉移bitcoine中
https://developers.coinbase.com/docs/merchants/payment-buttons
這裏PHP 代碼,請看看
<?php
$guid = "GUID_HERE";
$firstpassword = "PASSWORD_HERE";
$secondpassword = "PASSWORD_HERE";
$amounta = "10000000";
$amountb = "400000";
$addressa = "1A8JiWcwvpY7tAopUkSnGuEYHmzGYfZPiq";
$addressb = "1ExD2je6UNxL5oSu6iPUhn9Ta7UrN8bjBy";
$recipients = urlencode('{
"' . $addressa . '": ' . $amounta . ',
"' . $addressb . '": ' . $amountb . '
}');
$json_url = "http://blockchain.info/merchant/$guid/sendmany?password=$firstpassword&second_password=$secondpassword&recipients=$recipients";
$json_data = file_get_contents($json_url);
$json_feed = json_decode($json_data);
$message = $json_feed->message;
$txid = $json_feed->tx_hash;
?>
嘗試這個BTC
$transaction = Transaction::send();
$transaction->setToBitcoinAddress('here btc address to transfer');
$transaction->setAmount(new Money(0.0010, CurrencyCode::BTC));
$transaction->setDescription('this is optional');
希望將工作代碼轉移:
你有什麼麻煩?你有什麼嘗試? – Lolmewn
我嘗試了下面的鏈接代碼「第一個應用程序與Coinbase API」https://www.sitepoint.com/bitcoin-php-coinbases-api-demo-app/ – Priya
你有什麼想法如何使用下面的鏈接在PHP https: //www.sitepoint.com/bitcoin-php-coinbases-api-basic-usage/我運行了作曲家更新命令並得到了文件夾,但我不明白如何在php中使用文件夾 – Priya