Hi,
Is it possible to do a form POST and also redirect to a different url,
using code behind?
I don't think response.redirect will work because that doesn't post
form data.
I don't think server.transfer will work because that doesn't redirect
to a different url.
I don't think HttpWebRequest will work because that doesn't redirect
to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when
you click on it, it redirects to a credit card payment site, with the
form's data posted to this website, such as the total amount, etc,
etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw. 5 1562
The limitation of one form on an ASP.NET page is limited only to those
that you wish to control via ASP.NET. I would suggest putting in a
normal HTML form with an action to wherever you want and a method of
POST. No server side interaction will be done - and I assume this is
what you want.
On 11 Apr 2004 09:13:42 -0700, do***@hotmail.com (Dot net work) wrote: Hi,
Is it possible to do a form POST and also redirect to a different url, using code behind?
I don't think response.redirect will work because that doesn't post form data. I don't think server.transfer will work because that doesn't redirect to a different url. I don't think HttpWebRequest will work because that doesn't redirect to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when you click on it, it redirects to a credit card payment site, with the form's data posted to this website, such as the total amount, etc, etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw.
The limitation of one form on an ASP.NET page is limited only to those
that you wish to control via ASP.NET. I would suggest putting in a
normal HTML form with an action to wherever you want and a method of
POST. No server side interaction will be done - and I assume this is
what you want.
On 11 Apr 2004 09:13:42 -0700, do***@hotmail.com (Dot net work) wrote: Hi,
Is it possible to do a form POST and also redirect to a different url, using code behind?
I don't think response.redirect will work because that doesn't post form data. I don't think server.transfer will work because that doesn't redirect to a different url. I don't think HttpWebRequest will work because that doesn't redirect to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when you click on it, it redirects to a credit card payment site, with the form's data posted to this website, such as the total amount, etc, etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw.
Here's some ideas for you.
1) Output an old fashioned non-server form to the client (without the runat=
'server' attribute) Set the action attribute like you would have in
ASP.OLD, and use javascript to submit the form.
2) use client side script to change your ASP.NET form action attribute
3) use this webform control: http://www.wilsondotnet.com/Controls/
--
I hope this helps,
Steve C. Orr, MCSD, MVP http://Steve.Orr.net
"Dot net work" <do***@hotmail.com> wrote in message
news:77**************************@posting.google.c om... Hi,
Is it possible to do a form POST and also redirect to a different url, using code behind?
I don't think response.redirect will work because that doesn't post form data. I don't think server.transfer will work because that doesn't redirect to a different url. I don't think HttpWebRequest will work because that doesn't redirect to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when you click on it, it redirects to a credit card payment site, with the form's data posted to this website, such as the total amount, etc, etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw.
Hi,
Much appreciate all replies.
Under the asp.net "Pay" button, I think I might need a mixture of code
behind and client side programming?
ASPNET_Pay_Button_Click
If the user needs to do something different then
response.redirect("Another server side aspx form") 'In other words,
carry on doing typical asp.net server side type activities
else if the user wants to go ahead and pay me then
redirect and post some data using the asp.old way to a payment
website
else
'more code behind programming goes here.
Is it possible to get any of your client side suggestions inside the
code behind pay button so that I can post and redirect to the payment
website?
(I'd buy the component mentioned, but I haven't got a spare $50 at the
moment.)
-dnw. do***@hotmail.com (Dot net work) wrote in message news:<77**************************@posting.google. com>... Hi,
Is it possible to do a form POST and also redirect to a different url, using code behind?
I don't think response.redirect will work because that doesn't post form data. I don't think server.transfer will work because that doesn't redirect to a different url. I don't think HttpWebRequest will work because that doesn't redirect to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when you click on it, it redirects to a credit card payment site, with the form's data posted to this website, such as the total amount, etc, etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw.
I think I've done it. (Critical comments are very welcome.)
Under the asp.net "Pay" button, you can have the following code behind
code:
ASPNET_Pay_Button_Click
If the user needs to do something different then
response.redirect("Another server side aspx form") 'In other words,
just carry on doing typical asp.net server side type activities
else if the user wants to go ahead and pay me then
Response.Write("<form name='Form1' action='http://www.domain.com'
method='POST' >")
Response.Write("<input type='hidden' name='SomeDataThatNeedsPosting'
value='12345' >") 'The nice thing about this is that you can
construct the html values at run time using code behind.
Response.Write("</form>")
Response.Write("<script>")
Response.Write("document.Form1.submit();")
Response.Write("</script>")
else
'more code behind programming goes here.
Thank you for all help.
-dnw. do***@hotmail.com (Dot net work) wrote in message news:<77**************************@posting.google. com>... Hi,
Much appreciate all replies.
Under the asp.net "Pay" button, I think I might need a mixture of code behind and client side programming?
ASPNET_Pay_Button_Click If the user needs to do something different then response.redirect("Another server side aspx form") 'In other words, carry on doing typical asp.net server side type activities else if the user wants to go ahead and pay me then redirect and post some data using the asp.old way to a payment website else 'more code behind programming goes here.
Is it possible to get any of your client side suggestions inside the code behind pay button so that I can post and redirect to the payment website?
(I'd buy the component mentioned, but I haven't got a spare $50 at the moment.)
-dnw. do***@hotmail.com (Dot net work) wrote in message news:<77**************************@posting.google. com>... Hi,
Is it possible to do a form POST and also redirect to a different url, using code behind?
I don't think response.redirect will work because that doesn't post form data. I don't think server.transfer will work because that doesn't redirect to a different url. I don't think HttpWebRequest will work because that doesn't redirect to the url, it only posts data to it.
I want to have an code behind asp.net button called "Pay", and when you click on it, it redirects to a credit card payment site, with the form's data posted to this website, such as the total amount, etc, etc.
The cc payment site expects an old fashioned form post btw.
Is a code behind solution not possible?
Thanks for any expert opinion.
-dnw. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Manu |
last post by:
Hi there,
I am using a perl script to generate this html page which just
redirects users to my ftp server. The problem is I get a "page cannot
be displayed" in IE 6.0 (haven't tried other...
|
by: Rick N. Backer |
last post by:
Hello folks,
Novice type question here.
I'm working with a very simple app here that takes a series of strings
from the console. Once the end user has finished inputting the
strings they are...
|
by: Gerard M Foley |
last post by:
Can one write a webpage which is not displayed but which simply redirects
the user to another page without any action by the user?
Sorry if this is simple, but I am sometimes simple myself.
...
|
by: Steph |
last post by:
Bonjour,
Je souhaite lancer une redirection vers un fichier php via SRC= dans une
condition if (voir ci-dessous en bas du script) mais la redirection ne
fonctionne pas. Par contre la condition...
|
by: John Drako |
last post by:
I have a database with a lot of links. Every so often I run a script to
verify if the URLs are still valid. I weed out the ones with the 404
response.
However, many responses are of the 303 kind...
| |
by: denis |
last post by:
Hi there,
I got a tough interview questions lately, and I would like to hear
your opinion:
An array of N chars is given
Write an efficient algorithm to find all the repeating substring with a
...
|
by: souissipro |
last post by:
Hi,
I have written a C program that does some of the functionalities
mentionned in my previous topic posted some days ago. This shell
should:
1- execute input commands from standard input,...
|
by: Mike Hofer |
last post by:
I really need some help, and I'd appreciate any that you folks can
provide.
The ASP.NET application in question uses version 1.1 of the .NET
Framework. All of the pages use a common base class...
|
by: postindex |
last post by:
Can I get whole commandline not only argument list.
1. When I command like this
$ a.py filename
2. sys.argv is returns only argument list
Is there a way to find out 'redirection'...
|
by: Jim Rutledge |
last post by:
ok ok , anyone know anything on this tough question?
How do you determine the length in seconds that a midi file is , or any
audio file for that matter ?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |