whats the best way to implement text feedback after entering the two fields and clicking SUBMIT?
+3
A:
In your Controller you can either set
if ($this->Items->save($this->data)) {
$this->Session->setFlash('Your data has been submitted');
$this->redirect(array('action'=>'index'));
} else {
$this->Session->setFlash('Error saving the data');
}
http://book.cakephp.org/view/400/setFlash
or
if ($this->Items->save($this->data)) {
$this->flash('Your data has been submitted', '/items/', 5);
}
harpax
2010-02-04 08:09:39
A:
Alternatively you could redirect to a 'successful completion' page. Some third parties, like eBay, may require you to do this.
Decide how you want your application to behave and implement it that way!
Leo
2010-02-04 14:00:04