[Zope] Null value from Form Input
Montagne, Michael
montagne@BOORA.com
Thu, 13 Sep 2001 17:36:17 -0700
I have a form with a series of radio buttons that allow rating 1-5. In
order to make it easier to get an average of those numbers, I'd like to
allow NULL inputs. A snippet of my SQL method to update the database is:
INSERT INTO tblContactEval (responsiveness)
VALUES(<dtml-sqlvar responsiveness type="int" optional>);
The form looks something like this:
<input type=radio name=responsiveness value=1>1 
<input type=radio name=responsiveness value=2>2 
<input type=radio name=responsiveness value=3>3 
<input type=radio name=responsiveness value=4>4 
<input type=radio name=responsiveness value=5>5 
When I do not check any radio button in that group I get a "Bad Request"
error citng the "responsiveness" variable. How can I get a NULL value into
my database for those situations where this category does not apply?
thanks,
mjm