所以我有这个代码在PHP上运行完美
你可以看到它创建一个HTML表单并使用javascript ...
提交任何想法如何与c sharp相同?
public function redirect_url(){
//print_r($this->response);exit;
$content = <<<EOT
<SCRIPT LANGUAGE="Javascript" >
<!--
function OnLoadEvent() { document.downloadForm.submit(); }
//-->
</SCRIPT>
<body OnLoad="OnLoadEvent();">
<form name="downloadForm" action="{$this->response['result']['A']}" method="POST" >
<INPUT type="hidden" name="ONE" value="{$this->response['result']['B']}" >
<input type="hidden" name="TWO" value="$this->return_url" >
<input type="hidden" name="THREE" value="{$this->response['result']['D']}" >
</form>
</body>
EOT;
echo $content;exit;
}
答案 0 :(得分:0)
在c#中,您只需创建html文件并执行
Response.Redirect("pathtomyhtmlpage.html");