Connecting Tech Pros Worldwide Help | Site Map

Forced submit

 
LinkBack Thread Tools Search this Thread
  #1  
Old September 5th, 2008, 07:45 PM
Ellie
Guest
 
Posts: n/a
Default Forced submit

How can I force a submit on a form. I want to load a form but then I want to
close it and have it do something and then redirect it. This is ASP 3.0.
thanks


  #2  
Old September 5th, 2008, 08:45 PM
=?Utf-8?B?T2xkIFBlZGFudA==?=
Guest
 
Posts: n/a
Default RE: Forced submit



"Ellie" wrote:
Quote:
How can I force a submit on a form. I want to load a form but then I want to
close it and have it do something and then redirect it. This is ASP 3.0.
<body onLoad="document.forms[0].submit( );">

Assuming it is first form on the page.


  #3  
Old September 5th, 2008, 08:45 PM
Evertjan.
Guest
 
Posts: n/a
Default RE: Forced submit

=?Utf-8?B?T2xkIFBlZGFudA==?= wrote on 05 sep 2008 in
microsoft.public.inetserver.asp.general:
Quote:
"Ellie" wrote:
>
Quote:
>How can I force a submit on a form. I want to load a form but then I
>want to close it and have it do something and then redirect it. This
>is ASP 3.0.
>
<body onLoad="document.forms[0].submit( );">
>
Assuming it is first form on the page.
>
Indeed, the whole concept of form and submitting is clientsiide, not ASP.

You cannot close a form.

You cannot redirect a form.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
  #4  
Old September 5th, 2008, 08:55 PM
Bob Barrows [MVP]
Guest
 
Posts: n/a
Default Re: Forced submit

Ellie wrote:
Quote:
How can I force a submit on a form. I want to load a form but then I
want to close it and have it do something and then redirect it. This
is ASP 3.0. thanks
I don't understand ... why load the form in the first place? Just
process the data and redirect to the page you really want to go ... ?

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.


  #5  
Old September 5th, 2008, 09:15 PM
Ellie
Guest
 
Posts: n/a
Default Re: Forced submit

Probably because I don't know what I'm doing! I have to upload a file but it
doesn't work if I try to put it in the same asp page as all of the other
processing. I have to add the ENCTYPE="multipart/form-data" to the form
statement which my page doesn't seem to like. I didn't know I could have
more than one form on a page??? This does open up a lot more possibilitie
but it seems I can get that accomplished with having a redirect to a form
input page, pass it the file information to upload, submit the form and then
redirect it back to what the original page was doing.

"Bob Barrows [MVP]" <reb01501@NOyahoo.SPAMcomwrote in message
news:%23CDfOh5DJHA.936@TK2MSFTNGP03.phx.gbl...
Quote:
Ellie wrote:
Quote:
>How can I force a submit on a form. I want to load a form but then I
>want to close it and have it do something and then redirect it. This
>is ASP 3.0. thanks
>
I don't understand ... why load the form in the first place? Just
process the data and redirect to the page you really want to go ... ?
>
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
>
>
  #6  
Old September 5th, 2008, 10:55 PM
Evertjan.
Guest
 
Posts: n/a
Default Re: Forced submit

Ellie wrote on 05 sep 2008 in microsoft.public.inetserver.asp.general:
Quote:
I can get that accomplished with having a redirect to a form
input page, pass it the file information to upload, submit the form
and then redirect it back to what the original page was doing.
>
You cannot do anything clientside, like submit a form,
and after that do a serverside redirect.

And a clientside redirect, what is that?

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
  #7  
Old September 6th, 2008, 07:35 AM
Anthony Jones
Guest
 
Posts: n/a
Default Re: Forced submit

"Ellie" <ellymay999nospam@nospamnetzero.comwrote in message
news:O8Cr8o5DJHA.340@TK2MSFTNGP03.phx.gbl...
Quote:
Probably because I don't know what I'm doing! I have to upload a file but
it doesn't work if I try to put it in the same asp page as all of the
other processing. I have to add the ENCTYPE="multipart/form-data" to the
form statement which my page doesn't seem to like. I didn't know I could
have more than one form on a page??? This does open up a lot more
possibilitie but it seems I can get that accomplished with having a
redirect to a form input page, pass it the file information to upload,
submit the form and then redirect it back to what the original page was
doing.
>
What are you using on the serverside to receive the file?

When using multipart/form-data encoding ASPs Request.Form collection is not
able to return the field contents. The fields are there but encoded as mime
parts which ASP doesn't understand. Some serverside uploader tools allow
you to access these fields. Without this sort of support it will be
difficult to achieve what you want in a pure HTML form.

Note that a file input cannot be initialised with a file path. Hence any
plan to have the response form an ordinary post to automatically send
another post containing the file will fail.


--
Anthony Jones - MVP ASP/ASP.NET

 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.