Questions tagged [php]

Integrating Bitcoin services with the help of PHP-based frameworks or using PHP

Filter by
Sorted by
Tagged with
0
votes
0answers
11 views

Bit-Wasp using PrivateKeyFactory::fromWif PHP gives Deprecated ERROR [on hold]

in my script this line of code using Bit-Wasp library for PHP: $priv = PrivateKeyFactory::fromWif($privateKey); Gives me Deprecated: Non-static method BitWasp\Bitcoin\Key\Factory\PrivateKeyFactory:...
1
vote
1answer
48 views

how do I use the getwalletinfo RPC?

I can't seem to get a firm grasp of how to use the getwalletinfo RPC in the cmd line as well as in PHP code, The documentation says getwalletinfo doesn't take any parameters, but I've seen ways to ...
0
votes
0answers
32 views

How do I request fund using coinbase api

Hi I am trying to use coinbase api in php.api implementation working fine, I can check balance, creat new address all this are working fine.But facing problem on request bitcoin. I am following ...
0
votes
1answer
53 views

Pay with Bitcoin?

I want to add Bitcoin payments on my website. I've found some PHP library, but as far as I understand it's using only one wallet for incoming payments, and possibly just tracking for confirmations. Is ...
0
votes
2answers
112 views

How can I accept Bitcoin as a payment without a 3rd party gateway

I want to create a website where users can pay with Bitcoin. However I want to create my own payment gateway because I do not want to rely on services like BitPay. I want a unique BTC address for ...
0
votes
1answer
40 views

Run specific RPC commands in PHP?

I'm trying to get the balance of a specific address in my PHP session, I currently have this: <?php require 'header.php'; include 'Includes/Bitcoin/easybitcoin.php'; $bitcoin = new Bitcoin('...
0
votes
1answer
59 views

How to split the funds and send X% to fee wallet and the remaining funds to another wallet?

Anybody have any idea about how to do it? User send the bitcoins X% goes to fee wallet remaining funds goes to service wallet I'm trying to use the "sendfrom" but it's not working because he only ...
0
votes
0answers
119 views

Get Coinbase.com miner fee before sending to another address

I am using coinbase.com php library to send bitcoin to another address. But every-time i am sending bitcoin the fee is shown to me after sending the bitcoin. This is causing me some problem. Is there ...
0
votes
1answer
158 views

Creating a raw bitcoin transaction and signing it with the private key using php and javascript

I have a full bitcoin core node setup and would like to use it to just "broadcast" my signed transactions. But what is required to make a raw transaction using PHP and Javascript? The variables I have ...
1
vote
3answers
85 views

Generating bitcoin wallets for my customers [closed]

I run an application written in PHP and need to add the option to buy services with bitcoins. So, for each user i need to generate a unique, unused bitcoin address. I could generate X number wallets ...
0
votes
1answer
276 views

How to connect to a public node through json RPC?

I found a list of public bitcoin nodes here. I am using a php library. How can I connect to these nodes via JSON RPC? Is it safe to connect to public nodes? What should I give as username and ...
2
votes
1answer
237 views

Why a flip a bin before hashing in this script?

From How can I make this PHP merkle root script recursive? function binFlipByteOrder($string) { return implode('', array_reverse(str_split($string, 1))); } Why a flip?
1
vote
0answers
26 views

How to detect if there is new payments [closed]

I want to make a cryptocoin payments php in my website, all info already ok. The only problem is, how to know if my member already pay that payments and if already pay update my database, anybody ...
0
votes
1answer
150 views

update to 0.17.0 broke several rpc api calls that worked under 0.16.3, how to migrate correcty my code?

After updating from Bitcoin core 0.16.3 to 0.17 I've found several RPC calls are now broken, and I'm not sure on how to migrate/update my code (PHP). Things broken so far: getbalance : does not ...
1
vote
1answer
222 views

PHP How can I validate / verify a wallet public key?

Can someone please help me find some PHP open source on how to validate / verify a bitcoin wallet public key ? I am currently working on a project and I am implementing multisig, and it seems I can't ...
0
votes
1answer
607 views

Raw Transaction Fee - 256: absurdly-high-fee error [duplicate]

I'm running the following codes, respectively. bitcoin-cli -testnet createrawtransaction ''' [ { "txid":"751b6361cd8d621de00466363120e5da2176c3cc092cb3f0b7373b02591372d2", "vout" : ...
1
vote
0answers
225 views

block.io + scan generated QR code

So i created a block.io account and playing around with bitcoin address generation, as well QR codes. My source code for generating a new bitcoin address is that one: include_once("payment/block_io/...
0
votes
2answers
117 views

blockchain official documentation

I am developing a system of administrative management. The project is migrating from PHP to C ++. With the new requirements we want to work with blockchain. But when looking for more about it, ...
0
votes
1answer
130 views

Calculate fees with Blocktrail/btc.com SDK

First of all hi and thanks for your support and your time. I want to calculate the fees of a blocktrail transaction with blocktrail SDK, before making the transaction, in order to let the recipient ...
3
votes
1answer
799 views

Sweeping a bitcoin private key using PHP

Is there a PHP script where it validates a bitcoin private key and also gets the public address from the key? My goal was to: verify the private key Get the public address using that private key ...
0
votes
1answer
237 views

how can i get data from GDAX Bitfinex using API and show like bottom

how can i get and show below link data, can someone please help me https://runcoders.com/live-bitcoin/ i am trying by this but failed to show like up link <?php //define API endpoint $url = "...
0
votes
1answer
211 views

Handling change addresses without using rawtransactions?

Since I'm using the wonderful accounts feature which is soon to be deprecated (shame on me, i know - but i simply didn't have resources and time as a single person to do an internal accounting system ...
0
votes
1answer
156 views

How to get lost passphrase?

I set up the bitcoin daemon and galaxycash daemon on my server. And i was using this library easybitcoin.php to contact the daemon via rpc . Somehow i remeber that i used this function ...
1
vote
1answer
1k views

Is there a way to generate new addresses for someone else's wallet?

I thought I saw this feature existed somewhere but I can't find the reference. Use Case: Alice needs to keep sending multiple bitcoin transactions to Bob, and wants to use a different payment address ...
1
vote
2answers
834 views

PHP functions not working in bitcoin JSON-RPC version 16 (bitcoin-cli is working properly)

Trying to implement Bitcoin JSON-RPC using Digital Ocean Ubuntu using bitcoin version 16. Here is my php code <?php require_once('easybitcoin.php'); $bitcoin = new Bitcoin('someusername', '...
1
vote
2answers
922 views

How to create hex of raw transaction

Below is my response after creating the transaction. How do I create the hex encoded string of raw transaction in PHP. Is there package for it in PHP ? { "tx": { "block_height": -1, ...
0
votes
1answer
544 views

bitcoind is refusing to connect to my other server [closed]

bitcoind is refusing to connect to my other server
0
votes
1answer
280 views

Recognize Bitcoin address from block hash, and transaction hash

I'm building a block explorer using blockchain.info and their API https://github.com/blockchain/api-v1-client-php/blob/master/docs/blockexplorer.md but what I don't understand is, what is the best ...
0
votes
0answers
167 views

blockchain api missing file?

https://github.com/blockchain/api-v1-client-php <== php files im working with. When i do my first test with this new api i start off with the inits <?PHP // Include the autoload.php from its ...
1
vote
2answers
617 views

How to send bitcoins with commission extracted from payment in PHP or bitcoind

First, I have simple problem. I want to send customer some bitcoins, but I dont want to pay fees for him. I'd like to substruct fees from payment, so all commissions would be payed by customer. I ...
0
votes
1answer
322 views

how to get change address using derived BIP44 publicKey?

I have generated a private key using my master seed private key. PHP Code: $bip44 = HierarchicalKeyFactory::fromExtended($result['masterPrivKey']); $publicKey = $bip44->derivePath("m/44'/0'/0'")...
0
votes
1answer
2k views

Port 8333 and Issues to have a connection

So, I have a website, and that website is going to use Bitcoins. Right now, I'm trying to connect the bitcoin core with the website. But I have a lot of issues with port 8333: This is my error: http:...
0
votes
2answers
230 views

How to confirm transaction any altcoin PHP

I'm working on a webapp right now (for me personally) and I now come to the part where I want to validate if someone send me a certain amount of altcoin, lets say Verge, and if I received said amount ...
0
votes
0answers
353 views

How to sign a transaction hash in PHP?

Given the following example hash: 1ee917ec6ab6339e563d55abee50a49ccdb7d827cf087c0884f3da3b86e0dff4, and the following example private key: ...
3
votes
0answers
295 views

HD Wallets - Generating P2SH-P2WSH Addresses from a ypub-type mpks in PHP?

I am writing a webapp in PHP that needs to generate Bitcoin addresses from their mpk. I have successfully done it for P2SH addresses (starting with a 1, with a xpub mpk) using the BitWasp php library,...
1
vote
1answer
581 views

send bitcoin to mobile number or email address

How I can send bitcoins to someone's phone number or email address. I explored this api but they have documentation only for sending bitcoins to an address directly. But here they have explained how ...
1
vote
0answers
255 views

php call to getnewaddress through rpc gives isValid false address

I am using easybitcoin.php to make rpc calls to bitcoind running on my server. When I call $result = $bitcoin->getnewaddress(); from the php code, I get back an address, however when I run that ...
1
vote
2answers
894 views

PHP: is there a way to convert a private ECDSA key to its corresponding public key?

As described here (https://en.bitcoin.it/wiki/Technical_background_of_version_1_Bitcoin_addresses) I am trying to convert a private ECDSA key to its corresponding public key. (See step1 and step2). I ...
0
votes
1answer
584 views

Creating Payment system using Blockchain API

I see a whole lot of websites using the blockchain API to create bitcoin wallets (if i am correct), send and receive payments, I know how to ordinarily make a payment system using C#/MSSQL or PHP/...
0
votes
1answer
186 views

Dynamic Transaction Hash Confirmation

I am working on a donation based community website (using PHP) where participants register for an account to participate. Each account carries the participant's bitcoin address. A participant makes a ...
0
votes
1answer
508 views

How to get an average bitcoin to USD price from different sources [closed]

I created a very simple php function to get the current price of bitcoin to USD here, //get from coin market $getCoinMarketPrice = getPrice('https://api.coinmarketcap.com/v1/ticker/bitcoin/?...
0
votes
2answers
429 views

development of bitcoin-abe like software

I am trying to develop something similar to bitcoin-abe, e.g. import whole blockchain into database. For database I currently using Redis - I know it will took lots of RAM, but lets suppose that is ...
1
vote
1answer
464 views

Connect to Bitcoin Node behind tor network

I configured my full bitcoin node behind tor (nowadays there aren't much bitcoin nodes behind tor network, this website: https://bitnodes.21.co/nodes/?q=Tor%20network tell us that there are just 323 ...
0
votes
1answer
76 views

does anyone know how to send the “exp” parameter in an Electrum request

I tried modifying the request so it would include a 3600 second expire time. (minutes - 1 hour) as shown in the example it returned an error the parameter was invalid. It shows - but as "null" curl ...
1
vote
2answers
219 views

trying to get text of a field in json rpc 2.0 response into ar PHP variable

I use json_decode to vardump a return which yields array(3) { ["jsonrpc"]=> string(3) "2.0" ["result"]=> array(13) { ["status"]=> string(7) "Pending" ["amount (BTC)"]=> string(10) "0.05130899" ["...
0
votes
1answer
123 views

Online bitcoin game

I'm trying to create multiplayer game using BTC to make bets. I have server and I am using PHP to let users create an account. How would I write a script where when a new user creates an account the ...
0
votes
1answer
291 views

Can I sign a text with a Bitcoin address using PHP only?

I have the following... Bitcoin Address: 1H2zzoAncRcQYihgTMYtX55ioXYErmYQQC Public Key: 021FE07FBBB27AD176F1E082950474CD6252FB86751B893BC0887962B008830798 WIF Key: ...
0
votes
1answer
1k views

how to generate a bitcoin address for each user that registers

I'm working on a marketplace type website and i want a bitcoin address to be generated for each user that registers an account. this needs to be done in php with no javascript
2
votes
1answer
227 views

How would I be able to show 24 open, high & low on my site made with php

I'm a self thought designer/developer that knows basic photoshp/css3/html5 and a little python/php. I have never used an API to fetch stats, so can you please point me in the right direction? I ...
0
votes
1answer
166 views

Bitcoind rpc AddLocal(ip:port) and Disover: IPv4 eth0: ip missing Amazon AWS CentOS

I have a server at DigitalOcean with Ubuntu installed and bitcoind with rpc which IS working. With my Amazon AWS CentOs server bitcoin-cli is working but not EasyBitcoin-PHP, it's returning 0: $...