I hope this is the right place to ask this. I have a form with a large
number of list menus. The default value is "0" (zero). Is there any
way to have either the form or the form mail script ignore any of the
list menus that are left at the default value? What I would like is
for the form results to show only the items for which a value other
than "0" has been selected. As it it is right now, the form results
show every item and it's hard to go through the entire list looking
for items that have a value of something other than "0".
Thanx
David DeCristoforo
Re: Form parsing question
am 10.09.2007 20:44:37 von jkorpela
Scripsit ( ) David De Cristoforo:
> I have a form with a large
> number of list menus.
Do you have a URL? "List menu" can mean different things.
> The default value is "0" (zero).
Maybe, maybe not. Have you set it to be the default?
> Is there any
> way to have either the form or the form mail script ignore any of the
> list menus that are left at the default value?
It depends on what you mean by "are left". You cannot distinguish the
situation where the user intentionally selects "0" from his skipping the
entire question, if "0" is indeed the default (preselected, initial) value.
> What I would like is
> for the form results to show only the items for which a value other
> than "0" has been selected.
Well, it's up to the form handler to do such things. It can ignore the value
of "0", or the value of "42".
> As it it is right now, the form results
> show every item and it's hard to go through the entire list looking
> for items that have a value of something other than "0".
It's impossible to others to see what you are really doing and trying to
accomplish, since you did not post a URL.
--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/
Re: Form parsing question
am 10.09.2007 20:52:24 von David De Cristoforo
Here is the URL of the form:
http://www.farmerskitchencafe.com/submeals/menu_form.html
> Well, it's up to the form handler to do such things. It can ignore the value
> of "0", or the value of "42".
That's what I need..for the "form handler" to ignore anything with the
value of "0". In this case the "form handler" is a "typical" form mail
pearl script.
> It's impossible to others to see what you are really doing and trying to
> accomplish, since you did not post a URL.
Sorry. The URL is above. And thanks for yoiur help.
DD
Re: Form parsing question
am 10.09.2007 20:54:25 von jmm-list-gn
( ) David De Cristoforo wrote:
> I hope this is the right place to ask this. I have a form with a large
> number of list menus. The default value is "0" (zero). Is there any
> way to have either the form or the form mail script ignore any of the
> list menus that are left at the default value?
>
Since you have to test for those form names in any case, what difference
does it make whether is does not exist or has a default value?
--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Re: Form parsing question
am 10.09.2007 21:00:39 von David De Cristoforo
> Since you have to test for those form names in any case, what difference
> does it make whether is does not exist or has a default value?
I don't understand what you are asking. Whether what does not exist?
DD
Re: Form parsing question
am 10.09.2007 21:34:50 von jkorpela
Scripsit David De Cristoforo:
> That's what I need..for the "form handler" to ignore anything with the
> value of "0". In this case the "form handler" is a "typical" form mail
> pearl script.
Unfortunately, a "typical" form mail script is simplistic: it just collects
data and sends it as an e-mail message. But if you have control over the
script (i.e., you can write it or modify it or make someone else to do that
by your wishes), it can of course perform a simple check on any field or on
selected fields, ignoring (for example) fields with a value of 0. It's just
an if statement, or some if statements.
Independently of this, a field for inputting a quantity would probably be
better handled using a text input field rather than
Re: Form parsing question
am 10.09.2007 22:01:39 von David De Cristoforo
> But if you have control over the
> script (i.e., you can write it or modify it or make someone else to do that
> by your wishes), it can of course perform a simple check on any field or on
> selected fields, ignoring (for example) fields with a value of 0. It's just
> an if statement, or some if statements.
Ahh, well, therin lies the rub. I am not so gifted though perhaps I
could find someone who was. I was hoping there might be something I
could code into the form that would do this.
> Independently of this, a field for inputting a quantity would probably be
> better handled using a text input field rather than
Re: Form parsing question
am 10.09.2007 22:29:55 von jkorpela
Scripsit David De Cristoforo:
> I was hoping there might be something I
> could code into the form that would do this.
I see. You could use some JavaScript code, invoked via an onsubmit attribute
in the
Re: Form parsing question
am 11.09.2007 01:22:55 von David De Cristoforo
> I see. You could use some JavaScript code, invoked via an onsubmit attribute
> in the