$this->Post->create($this->data);
if ($this->Post->validates()) {
// Data is good
}
else {
// Data contains errors
}
On May 15, 9:21 pm, Wojtek <[EMAIL PROTECTED]> wrote:
> I have a problem with validating data without saveing anything in
> database.
> For example this script work good
> if ($this->Post->save($this->data)) {
> $this->flash('blabla.','/posts');
>
> }
>
> but when I use some my function form is not validating
> if ($this->Post->myFunction($this->data)) {
> $this->flash('blabla.','/posts');
>
> }
>
> How can I manually use validating rules from model?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---