beforeValidate() is a model method. Model has it's own $data. But the $this->data you're thinking of (I think) is handed from the controller to the view. You would have to modify the controller's array, IOW. Perhaps you'd be better off adding those 2 values in Model::beforeSave().
On Wed, Sep 2, 2009 at 3:15 PM, Kyle Decot<[email protected]> wrote: > > I am having a little bit of trouble w/ my $this->data. When someone > submits the form, in my beforeValidate() method, I create two new > variables inside of $this->data ($this->data['Model']['lat'] && $this- >>data['Model']['lng'])...I I then want to pass those back to the view > if the validation of the rest of the form fails but when I pr($this- >>data) in my view, lat and lng are not there. How do I make sure those > values are passed back? Thank you for any help. > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
