RE: [PEAR] QF setConstants/exportValue
| From: | Daniel Kopp | Date: | Thu, 22 Apr 2004 13:40:29 +0000 |
| Subject: | RE: [PEAR] QF setConstants/exportValue | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-12034@lists.php.net to get a copy of this message | ||
Hi!
> My problem is that my buildForm function in its very end does this:
>
> $this->setConstants($container['values']['formname']);
> viewArray($container['values']['formname']);
>
> which does - also as control - output the values of the form that I just
> set.
>
> This outputs that fID is "" but in the form I get something different in
> the
> select box - even there is an option ""=>'something' for the selectbox.
I found the problem: the problem is hat setConstants does not set values
that are NULL. I got a field from the DB which was NULL which is sometimes
in php equal to '' (NULL=='' is TRUE)
So setConstants did not set it and instead the value was used.
Maybe it would be a good idea to set '' if the value is NULL or is that not
possible for some reason?
Thanks for your time!
Daniel