473,396 Members | 1,726 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Cannot submit to another form

I am converting my ASP code to ASP.NET but have run into a hard stop. On
several of my pages I must post data to a different page as a result of a
submit. With ASP.NET, however, it seems that the 'action' clause on a form
is ignored and it always posts to itself.

Now how, guys, do you manage to set up a form to post to PayPal, for
example?

What am I missing here?
Dec 4 '07 #1
5 1492
You can't change the "Action" attribute of the form, but you can set the
"PostBackUrl" property on the submit button.
"James R. Davis" <ji*@msgroup.orgwrote in message
news:Ok**************@TK2MSFTNGP03.phx.gbl...
>I am converting my ASP code to ASP.NET but have run into a hard stop. On
several of my pages I must post data to a different page as a result of a
submit. With ASP.NET, however, it seems that the 'action' clause on a
form
is ignored and it always posts to itself.

Now how, guys, do you manage to set up a form to post to PayPal, for
example?

What am I missing here?

Dec 4 '07 #2
..NET insists on setting its own action attribute for the form if you're using runat="server". To break away from the submit structure, you might try using postbackurl=" (your web page's name)" in the submit button.

EggHeadCafe - .NET Developer Portal of Choice
http://www.eggheadcafe.com
Dec 10 '07 #3
Thanks.

Yes, I have been able to make this work - that is, using a button with a
postbackurl field. However, there is no postbackurl capability when I want
to use an image instead of a button to initiate a submit.
Dec 11 '07 #4
Yes, I have been able to make this work - that is, using a button with a
postbackurl field. However, there is no postbackurl capability when I
want
to use an image instead of a button to initiate a submit.
How about ImageButton?

Dec 11 '07 #5
One step closer to what I want, but not quite there yet.

With your help I found out how to post to an out of application url. That
works perfectly. What it does, however, is take my users away from my site
and to the other site. What I really want to do is cause the other site to
be seen in a new window so that I do not lose my users should they go 'take
a look' at the other site.

Is there an ASP.NET function that can accomplish this for me in association
with the submit button?
<C Whitewrote in message news:20***********************@yahoo.com...
.NET insists on setting its own action attribute for the form if you're
using runat="server". To break away from the submit structure, you might
try using postbackurl=" (your web page's name)" in the submit button.
>


EggHeadCafe - .NET Developer Portal of Choice
http://www.eggheadcafe.com

Dec 12 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Matt | last post by:
My problem is when the user click the submit button, it will launch another new window for the request page. I want to confirm we cannot use JavaScript open window functions to open a request page?...
8
by: Matt | last post by:
I want to submit the form to the server without opening another page. When we do the following, it will submit the form data in myform to the IIS, and open page2.asp. <form name="myform"...
7
by: NetCoder | last post by:
Hi to all, I have made a script that uses both JavaScript and PHP. The script has a form and when it is submitted, a JavaScript confirmation box appears, asking the user to confirm their action....
8
by: wASP | last post by:
Hi, I'm having a problem referencing the elements within an object after a method of that object (a member function) has been activated with an onsubmit handler: - - - - - - - - ...
4
by: three-eight-hotel | last post by:
I'm somewhat of a newbie to PHP coding, but have developed a site using the technology, and have been pleasantly surprised by the capabilities offered. I am more comfortable in the ASP world,...
1
by: teenagelcruise | last post by:
hi, i have a problem with my code which is i cannot update and addnew data into the database but i can delete the data.plz give me an idea.this is my code that i wrote. <html> <head> <meta...
4
by: MichaelK | last post by:
Hello. I have all data already collected on the current page? I want to open another window with the form, fill the fields and submit that form. So basically the question is how can I fill all...
12
by: GuangXiN | last post by:
I want the file upload element disappear, instead of it, I place a text box and a button with my own css defination. but it doesn't work on IE7. What should I do now? <form action="upload.php"...
4
by: j1dopeman | last post by:
Hi, I'd like to use a button to save and then submit a form. I can set the onlick of the button to mahButton_click or submit, but I can't figure out how to do both. It looks like c# can't...
3
by: pinko1204 | last post by:
My Update function cannot successful update to sql table even don't have any error. Please help to check .....thx PHP1 <?php require_once 'header.php'; ?> <style type="text/css"> <!--
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
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...
0
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...
0
tracyyun
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...
0
agi2029
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 using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.