注册 登录
编程论坛 PHP技术论坛

哪位大大能帮忙把下面的PHP代码翻译成ASP.NET的?小弟感激不尽

hk2024304 发布于 2012-11-20 21:56, 589 次点击
程序代码:
$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; }
2 回复
#2
hk20243042012-11-20 22:07
没人么,要求不高啊,只要能翻译得能大概看懂就行了
#3
cnfarer2012-11-22 21:56
这个不可能完全等效.特别是如数组,两者相差太多.
1