#!/usr/bin/php '1.0', 'id' => true, 'method' => $method, 'params' => $args)); $ch = curl_init('http://127.0.0.1:8332'); echo($rpcuser.':'.$rpcpass."\n"); curl_setopt($ch, CURLOPT_USERPWD, $rpcuser.':'.$rpcpass); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $json); return curl_exec($ch); } $raw = '01000000000102c58d46102d08c26624d2326185cb968f89b9fc71c497345502ca9a5058772c6c0000000017160014edaa8e29e48f87e1c0c6c6e665724aa94378ac9ffdffffff1cd1e46cd7c48dc772fb2bbe67d58a6e49cd12709c4715488449c4b09bdb93760000000017160014ca79827c1c58630601e0f40a1f32d7b83d1fe72cfdffffff01bf238a25000000001600142e4747f3c7b5b466d91944811d05a5683af566c602483045022100fedbc1d99c7cd5077b0d9b0128f217b5dc6f6845cb38fd653e14c4ebd4c8d2f402205c3f888b5f67bfd0e4540f3de0baf00b5d58a1c89e3a35247123127bf6b7d47c01210329ddecdbd03edb034a73f1959c9289967f8ebad4f1bcf39073b8d6dbe3d1cde702483045022100b1aa08debab0025588746d35b2d32cbdf2ed1a5e37b89d4d8271893df82a777202201488bf6693f7f33ce5b960bd370811d56407084424a04f182d388e1e51055498012102fe8c1cdfd226430151e00f5b36986bdbaeb4dab23ef39fe2829f7bb55b0a645072980800'; $stuff = TransactionFactory::fromHex($raw); //print_r($stuff); echo(rpc('getrawtransaction', '496b6cc60ccc46df987b915e98a61db298a6d89b7eab7956bc166ab52e8e6836', 3)); ?>