Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $form = new Application_Form_Comment();
- $form->submit->setLabel('Comment');
- if ($this->getRequest()->isPost()) {
- $formData = $this->getRequest()->getPost();
- if ($form->isValid($formData)) {
- $comment = new Application_Model_DbTable_Comments();
- $comment->addComment($formData['comment'], $id);
- $this->_helper->redirector('index');
- } else {
- $form->populate($formData);
- }
- $this->view->form = $form;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement