I dont have a problem really...I just need help understanding why what I did works.
I have a controller called campaigns_controller, users can add campaigns, but when they do I need the users' post limit to decrease by 1. This is where the code form my add() function. if($this->Campaign->save($this->data)){ $limit = $active_user['0']['User']['limit'] - 1; $blah = $this->Campaign->User->id = $user_id; $blah = $this->Campaign->User->read('limit'); $blah = $this->Campaign->User->set('limit', $limit); print_r($blah); $this->Campaign->User->save($blah); $this->Session->setFlash('Campaign added', 'messages/win'); $this->redirect(array('action' => 'index'), null, true); } That code above didn't work btw...once I changed read('limit'); to read(); it worked fine...but I don't know why when I print blah, i get this array Array ( [User] => Array ( [limit] => 3 ) ) which doesn't look right. I need help understanding this better Any help is appreciated. Thanks 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