帮助HTTP POST VB.net/ASP.net [英] Help with HTTP POST VB.net/ASP.net

查看:72
本文介绍了帮助HTTP POST VB.net/ASP.net的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我需要在客户和银行之间设置交易以进行付款。总体方案是让客户点击我们网站上的一个按钮,该按钮将向银行网站发起HTTP POST。初次连接后,银行会收到回复,然后我们会回复,最后客户将在银行网站上完成交易。



最初的连接是模仿这个例子:



< form action =https:// hostname / pathmethod =post>

< input type =hiddenname =app_idvalue =0>

< input type =hiddenname =mess_vervalue =1.1 >

< / form>



所以,我的第一个问题是:如何在ASP.NET / VB中执行上述操作?



提前谢谢。

Hi all,

I need to setup transactions between our customers and a bank for payments. The overall scheme is to have the customers click on a button on our site that will initiate the HTTP POST to the bank site. After the initial connection, there will be a response from the bank then a response from us, then finally the customer will be on the bank site to complete the transaction.

The initial connection is to mimic this example:

<form action="https://hostname/path" method="post">
<input type="hidden" name="app_id" value="0">
<input type="hidden" name="mess_ver" value="1.1">
</form>

So, my fist question is: how to I do the above in ASP.NET/VB?

Thank you in advance.

推荐答案

在新的Web项目中创建一个ASPX页面并使用这用于表单代码:



< form id =form1action =https:// hostname / pathmethod =postrunat =server >

< asp:hiddenfield id =hidApp_idname =app_idvalue =0runat =server/>

< asp :hiddenfield id =hidMess_vername =我ss_vervalue =1.1runat =server/>

< / form>



从你的VB你可以现在:



hidApp_id.Value = x

hidMess_ver.Value = y
Create an ASPX page in a new web project and use this for the form code:

<form id="form1" action="https://hostname/path" method="post" runat="server">
<asp:hiddenfield id="hidApp_id" name="app_id" value="0" runat="server"/>
<asp:hiddenfield id="hidMess_ver" name="mess_ver" value="1.1" "runat="server" />
</form>

From your VB you can now:

hidApp_id.Value = x
hidMess_ver.Value= y


使用服务器侧控制并使用value属性从该控件获取值。



否则你可以使用sync java命令来使用像asp这样的任何其他服务器端控件:按钮并用于相同的目的。



问候,

Dattatray Gaonkar
Use the server side control and use the value property to get the value from that control.

else you can use the sync java hit to using any other server side control like a asp:button and serve the same purpose.

Regards,
Dattatray Gaonkar


这篇关于帮助HTTP POST VB.net/ASP.net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆