Re: HTML_QuickForm_Controller and setDefaults

From: Date: Tue, 12 Sep 2006 20:13:46 +0000
Subject: Re: HTML_QuickForm_Controller and setDefaults
References: 1 2 3 4 5 6 7  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-25119@lists.php.net to get a copy of this message
Hi, Kim Fredenberg wrote:
What versions of QuickForm and QuickForm_Controller are you using?
HTML_QuickForm            3.2.5    stable
HTML_QuickForm_Controller 1.0.5    stable
Try upgrading to QuickForm 3.2.6, it has one fix dealing with selects. If upgrade doesn't fix your problems open a bug report, since the stuff you are describing certainly looks like a bug.
Thanks, that fixed the problem with the select box! The problem with the checkbox remains, maybe the same bug? Can I get a diff somewhere that displays the changes made for the select? I could have a look at the checkbox and see if I can get it working before opening a bug report. Is this the bug you are describing? "* Default values for single-selects were ignored if form was considered submitted (bug #5269)"
Yes, exactly. Here is the relevant change: http://cvs.php.net/viewcvs.cgi/pear/HTML_QuickForm/QuickForm/select.php?r1=1.29&r2=1.30 I suspect the bug is actually somewhere in Controller (its isValid() method has a hackish special case for dealing with pages that were not seen by the user).

« previous php.pear.general (#25119) next »