public function indexAction() { $entries_hash = array(); $guestbook = new Application_Model_GuestbookMapper(); $this->view->entries = $guestbook->fetchAll(); // Initializing entries in hash format for partialLoop foreach ($this->view->entries as $entry) { $entries_hash[] = array("comment" => $entry->getComment(), "email" => $entry->getEmail()); } $this->view->entries_hash = $entries_hash; }
public function indexAction() { // action body $guestbook = new Application_Model_GuestbookMapper(); $this->view->entries = $guestbook->fetchAll(); }
public function indexAction() { $guestbook = new Application_Model_GuestbookMapper(); $this->view->entries = $guestbook->fetchAll(); $this->view->title = "Guests list"; }
public function indexAction() { $guestbook = new Application_Model_GuestbookMapper(); $this->view->entries = $guestbook->fetchAll(); $this->view->messages = $this->_helper->flashMessenger->getMessages(); }