Re: HTML_Quickform unserialize insanity.
| From: | Bertrand Mansion | Date: | Wed, 09 Jun 2004 12:28:37 +0000 |
| Subject: | Re: HTML_Quickform unserialize insanity. | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-13035@lists.php.net to get a copy of this message | ||
Ian P. Christian wrote:
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>I'm having an issue passing a serialized array in HTML_QuickForm_Controller.
>
>This error seems to be completely illogical, and I can't figure it out, so I
>thought I would ask here for a little help.
>
>On page1, I have this...
>
> $bbnumber = $this->controller->exportValue('page0', 'bbnumber');
> $result = $adsl_checker->CheckNumber($bbnumber);
>
> $resultField = $this->createElement('hidden', 'result');
I don't know if this is related but I would do :
$this->setDefaults(array('result' => $result));
$resultField =& HTML_QuickForm::createElement('hidden', 'result');
^^^^
$this->addElement($resultField);
Might not solve your problem but this looks cleaner to me.
Bertrand Mansion
Mamasam