How do I make an asp.net page submit to a specific IP address?
Every time the page submits (during postback) I wish to have it submit to a specific IP address? Is that possible in .net 3.5? Thanks in advance.
How do I make an asp.net page submit to a specific IP address?
Every time the page submits (during postback) I wish to have it submit to a specific IP address? Is that possible in .net 3.5? Thanks in advance.
In Asp.Net 3.5 (you must have Visual Studio SP1 installed) you can set the Form's action in the code behind page by using form.Action = 172.21.151.203
Please note that this will only work with the web application model and not on the web site model.
If you are relying on the user to interact with a Button for postback operations, then use the Button.PosbackUrl property. You can specify a completely different host.
How to: Post ASP.NET Web Pages to a Different Page
<asp:Button
ID="Button1"
PostBackUrl="~/TargetPage.aspx"
runat="server"
Text="Submit" />