I'm having some trouble with the $this->request->is('post') object and
hope I can get some answers here...
In my controller I have the following:
public function movie($action = "list", $id = "") {
if ($action == "single") {
if ($this->request->is('post')) {
// Saves the record
} elseif ($id != "") {
// Load record info
} else {
// Load blank form
}
// Load other informations...
$this->render('movie');
}
}
When i load a blank form at admin/movie/single and try to submit the
form it works just fine and my record is saved.
But, when i load a record using admin/filme/single/1 and try to update
it, $this->request->is('post') returns false, and nothing happens...
What am I doing wrong here?
--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
No comments:
Post a Comment