Also, you have unset the created_at and updated_at fields in your form but
you didn't remove them from the template, so the template is still trying to
load non-existant widgets which is exactly what the error message is telling
you.

<th><?php echo $form['created_at']-
>renderLabel() ?></th>

On Fri, Oct 23, 2009 at 12:59 PM, Mohammed Rhamnia <
mohammed.rham...@gmail.com> wrote:

>
> Hi,
> i try to disable created_at and updated_ut input in my ClassForm i
> have this :
> class TacheForm extends BaseTacheForm
> {
>  public function configure()
>  {
>    unset($this['created_at'], $this['updated_at']);
>  }
> }
>
> in the template i have
> <?php echo $form ?>
>
> When i try to see the result i get this exception :
>
> 500 | Internal Server Error | InvalidArgumentException
> Widget "created_at" does not exist.
> stack trace
>
>    * at ()
>      in SF_ROOT_DIR\lib\symfony\form\sfForm.class.php line 956 ...
>             953.     {
>             954.       if (!$widget = $this->widgetSchema[$name])
>             955.       {
>             956.         throw new InvalidArgumentException(sprintf
> ('Widget "%s" does not exist.', $name));
>             957.       }
>             958.
>             959.       if ($this->isBound)
>    * at sfForm->offsetGet('created_at')
>      in SF_ROOT_DIR\apps\frontend\modules\tache\templates\_form.php
> line 73 ...
>              70.         </td>
>              71.       </tr>
>              72.       <tr>
>              73.         <th><?php echo $form['created_at']-
> >renderLabel() ?></th>
>              74.         <td>
>              75.           <?php echo $form['created_at']->renderError
> () ?>
>              76.           <?php echo $form['created_at'] ?>
>
> Can any one help me?
>
> >
>


-- 
Gareth McCumskey
http://garethmccumskey.blogspot.com
twitter: @garethmcc

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to