|
|
#2
hk20243042012-11-20 22:07
|
程序代码:$apikey = '12345657898';
$params = array( 'user_id' => '12345',
'project_id' => '654321',
'hash' => $hash );
$context = stream_context_create(array('http' =>
array( 'header' => "Authorization: Basic " . base64_encode("$apikey:$apikey") )));
$url = 'https://www.sofortueberweisung.de/payment/paycode/get?';
$url .= http_build_query($params, null, '&');
$paycode = file_get_contents($url, false, $context);
if (strpos($paycode, 'Errors') === false)
{ echo $paycode; }
$params = array( 'user_id' => '12345',
'project_id' => '654321',
'hash' => $hash );
$context = stream_context_create(array('http' =>
array( 'header' => "Authorization: Basic " . base64_encode("$apikey:$apikey") )));
$url = 'https://www.sofortueberweisung.de/payment/paycode/get?';
$url .= http_build_query($params, null, '&');
$paycode = file_get_contents($url, false, $context);
if (strpos($paycode, 'Errors') === false)
{ echo $paycode; }
要求不高啊,只要能翻译得能大概看懂就行了