Ask a Question related to ASP.NET General, Design and Development.
-
Jonathan Amend #1
Multiple Forms
I want to make a page that has 2 forms on it but I can't use any
runat=server controls because there can only be one runat=server form. Is
there a way of having 2 forms with runat=server controls or do I have to
resort to normal forms with submit burrons and processing the request
manually when Page_Load fires?
Jonathan Amend Guest
-
Multiple Forms in one page
Is there any way to have multiple forms in one page without having the forced space between the submit buttons that each form has? In other... -
processing multiple forms
Hi, I am currently using several forms for submitting data and as each form is submitted then it is delt with and then the next page is called. But... -
Multiple forms on one page
I am trying to put together a stripped-down online order form that allows a user to enter quantities ordered for a bunch of products, as well as... -
SSL Forms Login for multiple sites
Hi, SSL newbie would love some advice :-) I have a server that hosts several independant domains (using host headers to differentiate them).... -
How to include multiple <forms> on one ASP.NET page
Hi, I need to create an ASPX page that includes both traditional HTML Forms (which are submitted to a third-party site like a travel booking... -
Victor Garcia Aprea [MVP] #2
Re: Multiple Forms
Hi Jonathan,
If you really, really, *really* need two server-side forms, then check out
Paul's[1] site which includes such a control.
[1] [url]http://www.wilsondotnet.com/[/url]
--
Victor Garcia Aprea
Microsoft MVP | ASP.NET
Looking for insights on ASP.NET? Read my blog:
[url]http://obies.com/vga/blog.aspx[/url]
To contact me remove 'NOSPAM'. Please post all questions to the newsgroup
and not by private mail.
"Jonathan Amend" <cephas_is@hotmail.com> wrote in message
news:3f14b5f5$1_1@aeinews....> I want to make a page that has 2 forms on it but I can't use any
> runat=server controls because there can only be one runat=server form. Is
> there a way of having 2 forms with runat=server controls or do I have to
> resort to normal forms with submit burrons and processing the request
> manually when Page_Load fires?
>
>
Victor Garcia Aprea [MVP] Guest
-
Steve C. Orr, MCSD #3
Re: Multiple Forms
You cannot have 2 runat=server forms on the same form unless one of them is
invisible.
One potential workaround is to use an IFrame.
Here's more info on IFrames:
[url]http://msdn.microsoft.com/workshop/author/dhtml/reference/objects/IFRAME.asp[/url]
--
I hope this helps,
Steve C. Orr, MCSD
[url]http://Steve.Orr.net[/url]
"Jonathan Amend" <cephas_is@hotmail.com> wrote in message
news:3f14b5f5$1_1@aeinews....> I want to make a page that has 2 forms on it but I can't use any
> runat=server controls because there can only be one runat=server form. Is
> there a way of having 2 forms with runat=server controls or do I have to
> resort to normal forms with submit burrons and processing the request
> manually when Page_Load fires?
>
>
Steve C. Orr, MCSD Guest
-
Dan Anderson #4
Multiple Forms
Is it possible to tell a browser to send form a to URL a and form b to
URL b?
(i.e. post to two different URLS)
Thanks,
-Dan
Dan Anderson Guest
-
Ray at #5
Re: Multiple forms
Well, one way would be by the data that was submitted.
Another way would be to use two separate action pages.
Another way would be to put a hidden input in both forms with the same name.
<input type="hidden" name="whichForm" value="1">
<input type="hidden" name="whichForm" value="2">
Don't go buy values of submit buttons or anything, since they're be empty if
the user ENTERs or Ctrl+Ms to submit.
Ray at work
"Joel Brabant" <joel.brabant@tembec.com> wrote in message
news:0fd001c3813a$c0bfd6f0$a001280a@phx.gbl...> If my page has 2 forms and I use POST on both that calls
> the itself, how can I know from my asp code which form was
> submitted.
>
> Thank You.
Ray at Guest
-
suntin #6
Multiple forms
Is it possible to tell the name of a form being submitted?
I have 2 forms on a page and want to choose an action depending on which one is submitted...
suntin Guest
-
Stressed_Simon #7
Re: Multiple forms
Put a seperate hidden field in each form tha identifies it. Or name your submit buttons different names!!
Make sense?
Stressed_Simon Guest
-
suntin #8
Re: Multiple forms
the hidden form field is something i thought of, just wanted a more elegant way of doing it...
But not following on the button names...
suntin Guest
-
Stressed_Simon #9
Re: Multiple forms
You have 2 forms right? So that means you have 2 submit buttons? Well submit
buttons should have a name attribute:-
<input type="submit" name="FirstForm" value="click here" />
Well if you give the two submit different names then you can differentiate
between the forms as depending on which button is clicked you will have a
variable called FORM.ChosenName.
Make sense?
Stressed_Simon Guest
-
Bill Goldner #10
Re: Multiple forms
You say you have two separate forms. Seems to me like you could add a URL
variable in the action attribute of the two <form> tags in order to identify
which form was submitted.
As for the button names, I think he was referring to one form having
multiple submit buttons; each with a different assigned value. Example:
[insert new], [edit], and [delete]. Upon submission of the form, the value
of the form's submit button used could be evaluated and the perscribed
action taken.
~Bill
"suntin" <webforumsuser@macromedia.com> wrote in message
news:d5snru$5c3$1@forums.macromedia.com...> the hidden form field is something i thought of, just wanted a more
> elegant way of doing it...
>
> But not following on the button names...
Bill Goldner Guest
-
odette007 #11
Re: Multiple forms
.....you might want to use if clause...something such...
<cfif ISDefined("FORM.ChosenName")
<cflocation url=sendmethere.cfm>
<else><cfinclude template=theotherform.cfm>
</cfif>
odette007 Guest



Reply With Quote

