Hi,

you can check my post here and see if it - maybe - fits your needs.
Please, see last reply.

http://groups.google.com/group/cake-php/browse_thread/thread/2f6a264df0492006

Matteo

On May 22, 8:50 am, Ed Propsner <crotchf...@gmail.com> wrote:
> I have a form that is not displaying validation errors like it should be.
> The errors are there in the validationErrors array so the model is
> validating, I'm sure of that.
> I've been reading through a few other threads on the same subject but none
> of the causes seem to apply.
>
> I have the controller and the model stripped down to next to nothing.
>
> [controller]
>
> function add()
> {
> if(!empty($this->data))
> {
> $this->data['ProfileAttrib']['user_id'] = $this->Auth->User('id');
> $this->ProfileAttrib->save($this->data);
>
> }
> }
>
> [/controller]
>
> Then in the model I validate field 'gender'
>
> [model]
>
> class ProfileAttrib extends AppModel
>  {
>
> var $name = 'ProfileAttrib';
>
>  var $validate = array(
>       'gender' => array(
> 'rule' => 'notEmpty',
> 'message' => 'Message here'
> )
>      );
>
> }
>
> [/model]
>
> I also stripped down the view to just a form and a single field for gender.
> Whatever the reason is that validation messages aren't displaying I'm really
> not seeing it.
> I can't strip things down any more than what they are now.
>
> Any advice?
>
> - Ed
>
> Check out the new CakePHP Questions sitehttp://cakeqs.organd help others with 
> their CakePHP related questions.
>
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> athttp://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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

Reply via email to