示例#1
0
 /**
  * Executes paragraphCreate action
  *
  * @param sfRequest $request A request object
  */
 public function createNewParagraph($id)
 {
     $paragraph = new Paragraph();
     $paragraph->setIdContent($id);
     $paragraph->save();
     if (!$paragraph->getId()) {
         // action on error
         exit;
     }
     return $paragraph;
 }