This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Webmaster forum > November 2006 > processing form types





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author processing form types
William Tasso

2006-11-19, 7:58 pm

Greetings one and all

I have a page which contains several forms. One/some of these forms is a=
=

file upload form which needs the attribute: enctype=3D"multipart/form-da=
ta"

Is it possible to process all forms using the same script? Normally I'd=
=

simply test for the value of the 'submit' button but this is not possibl=
e =

in this situation.

FWIW: This is classic ASP/vbScript but I can probably do an inline =

translate from other environments/languages if there's a solution.

Thanks for reading.
-- =

William Tasso

http://williamtasso.com/words/what-is-usenet.asp
Benjamin Niemann

2006-11-19, 7:58 pm

William Tasso wrote:

> Greetings one and all
>
> I have a page which contains several forms. One/some of these forms is a
> file upload form which needs the attribute: enctype="multipart/form-data"
>
> Is it possible to process all forms using the same script? Normally I'd
> simply test for the value of the 'submit' button but this is not possible
> in this situation.
>
> FWIW: This is classic ASP/vbScript but I can probably do an inline
> translate from other environments/languages if there's a solution.


Not sure, if I understand the question correctly...

You could add a hidden field to each form, so the script knows which form it
has to handle.
You may also add different query strings to the FORMs action (if all forms
use POST).

Most environments should be able to handle the two different enctypes
transparently, so you probably don't have to worry about this.


HTH

--
Benjamin Niemann
Email: pink at odahoda dot de
WWW: http://pink.odahoda.de/
Karl Groves

2006-11-19, 7:58 pm

Benjamin Niemann <pink@odahoda.de> wrote in news:eja1tg$mgt$1@online.de:

> William Tasso wrote:
>
>
> Not sure, if I understand the question correctly...
>
> You could add a hidden field to each form, so the script knows which
> form it has to handle.
> You may also add different query strings to the FORMs action (if all
> forms use POST).
>
> Most environments should be able to handle the two different enctypes
> transparently, so you probably don't have to worry about this.
>
>


To add:
IMO this should be painless so long as each form element is named
differently.


--
Karl Groves
www.karlcore.com
William Tasso

2006-11-19, 7:58 pm

Fleeing from the madness of the 1&1 Internet AG jungle
Benjamin Niemann <pink@odahoda.de> stumbled into news:alt.www.webmaster
and said:

> William Tasso wrote:
>
s a[color=darkred]
[color=darkred]
I'd[color=darkred]
[color=darkred]
>
> Not sure, if I understand the question correctly...
>
> You could add a hidden field to each form, so the script knows which =


> form it
> has to handle.
> You may also add different query strings to the FORMs action (if all =


> forms
> use POST).
>
> Most environments should be able to handle the two different enctypes
> transparently, so you probably don't have to worry about this.


Brilliantly obvious - thanks. The querystring did it for me.

dunno why I didn't think of that :)
-- =

William Tasso

http://williamtasso.com/words/what-is-usenet.asp
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews