[Zope] Empty lines in forms?

Lennart Regebro lennart@regebro.nu
Thu, 24 Jan 2002 18:08:12 +0100


I have a select box in a form that returns a lines setting. If course, as
the status are with the incredibly stupid HTML standard, if nothing is
selected, the request variable doesn't exist. To fix this I tried doing
this:

<input type="hidden" name="foobar:lines:default" value="">

As expected, when nothing was selected I now got a default value. Great.
But, the default value was not the empty list I wanted, but it was [''], a
list with an empty string! I tried changing the value to "[]" which only
resulted in ['[]'] which was even more wrong... OK, it wasn't a problem,
since I was using it for a search-form, and [''] in a catalog search will
give the same results as [], but it still is the wrong result.

Now for the question: I'm I stupid and missing something essential here, or
is this a bug?

I'm using Zope 2.3.3.