function check() { if (trim($this->title) == '') { $this->setError(JText::_('COM_PHOCAGUESTBOOK_GUESTBOOK_MUST_HAVE_TITLE')); return false; } if (empty($this->alias)) { $this->alias = $this->title; } $this->alias = PhocaGuestbookHelper::getAliasName($this->alias); return true; }
function check() { /* // If in frontend it is not required if (trim( $this->title ) == '') { $this->setError( JText::_( 'COM_PHOCAGUESTBOOK_ITEM_MUST_HAVE_TITLE') ); return false; }*/ if (empty($this->alias)) { $this->alias = $this->title; } if (empty($this->date)) { $this->date = JFactory::getDate()->toMySQL(); } $this->alias = PhocaGuestbookHelper::getAliasName($this->alias); return true; }