-- Arthur M. Kang <[EMAIL PROTECTED]> wrote
(on Wednesday, 27 February 2008, 10:06 PM -0800):
> Thank you for taking the time to answer my questions. Replies below.
>
> Matthew Weier O'Phinney wrote:
>
> -- Arthur M. Kang <[EMAIL PROTECTED]> wrote
> (on Wednesday, 27 February 2008, 03:55 PM -0800):
>
>
> I have a couple of questions regarding Zend_Form if anyone can help...
>
> Setup:
> I'm using 1.5RC1 of the framework.
> Doing a simple test with:
>
> Action:
> $form = new Zend_Form(array(
> 'action' => '/user/test',
> 'method' => 'post',
> 'elements' => array(
> 'username' => 'text'
> )
> ));
> $this->view->form = $form;
>
>
> View:
> <?= $this->form ?>
>
> Questions:
>
> 1. If I put in $form->clearElements(); after I setup the form, I get:
> Warning: Corruption detected in form; invalid key found in
> internal
> iterator in /directory/Zend/Form.php on line 2125
> Is that a bug or am I doing something wrong?
>
>
>
> Could you clarify exactly when this happens? Does the exception occur
> when you call clearElements(), or when making another method call later
> after doing so?
>
> The exception occurs when the form is outputted in the view (<?= $this->form
> ?>). There are no further method calls. Just create the form, call
> clearElements, and then output the form. If this is a bug, I can file an
> issue.
I've confirmed, and filed the issue for you:
http://framework.zend.com/issues/browse/ZF-2754
--
Matthew Weier O'Phinney
PHP Developer | [EMAIL PROTECTED]
Zend - The PHP Company | http://www.zend.com/