/**
  * @see	\wcf\page\IPage::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['setNewsAsNew'])) {
         $this->setNewsAsNew = intval($_POST['setNewsAsNew']);
     }
 }
 /**
  * @see	\wcf\page\IPage::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['setEntryAsNew'])) {
         $this->setEntryAsNew = intval($_POST['setEntryAsNew']);
     }
     // quotes
     MessageQuoteManager::getInstance()->readFormParameters();
 }
Esempio n. 3
0
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['tags']) && is_array($_POST['tags'])) {
         $this->tags = ArrayUtil::trim($_POST['tags']);
     }
     if (isset($_POST['time'])) {
         $this->time = $_POST['time'];
     }
     if (isset($_POST['imageID'])) {
         $this->imageID = intval($_POST['imageID']);
     }
     if (isset($_POST['teaser'])) {
         $this->teaser = StringUtil::trim($_POST['teaser']);
     }
     if (MODULE_POLL && WCF::getSession()->getPermission('user.cms.news.canStartPoll')) {
         PollManager::getInstance()->readFormParameters();
     }
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (!empty($_POST['uploadID'])) {
         $this->uploadID = intval($_POST['uploadID']);
         $this->fileUpload = new FileUpload($this->uploadID);
     }
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['enableDelayedPublication'])) {
         $this->enableDelayedPublication = intval($_POST['enableDelayedPublication']);
     }
     if (isset($_POST['publicationDate'])) {
         $this->publicationDate = $_POST['publicationDate'];
     }
     if (isset($_POST['enableAutomaticArchiving'])) {
         $this->enableAutomaticArchiving = intval($_POST['enableAutomaticArchiving']);
     }
     if (isset($_POST['archivingDate'])) {
         $this->archivingDate = $_POST['archivingDate'];
     }
     if (isset($_POST['teaser'])) {
         $this->teaser = StringUtil::trim($_POST['teaser']);
     }
     if (isset($_POST['tags']) && is_array($_POST['tags'])) {
         $this->tags = ArrayUtil::trim($_POST['tags']);
     }
     if (isset($_POST['isHot'])) {
         $this->isHot = intval($_POST['isHot']);
     }
     // news picture
     if (NEWS_ENABLE_NEWSPICTURE) {
         if (isset($_POST['pictureID'])) {
             $this->pictureID = intval($_POST['pictureID']);
         }
         $this->picture = new NewsPicture($this->pictureID);
     }
     // sources
     if (NEWS_ENTRY_ENABLE_SOURCES && isset($_POST['sourceLink']) && is_array($_POST['sourceLink']) && isset($_POST['sourceText']) && is_array($_POST['sourceText'])) {
         $sourceLinks = $_POST['sourceLink'];
         $sourceTexts = $_POST['sourceText'];
         foreach ($sourceLinks as $index => $sourceLink) {
             $this->sources[$index] = array('sourceLink' => StringUtil::trim($sourceLink));
             if (isset($sourceTexts[$index])) {
                 $this->sources[$index]['sourceText'] = StringUtil::trim($sourceTexts[$index]);
                 unset($sourceTexts[$index]);
             }
         }
         foreach ($sourceTexts as $index => $sourceText) {
             $this->sources[$index] = array('sourceText' => StringUtil::trim($sourceText));
         }
     }
     // quotes
     MessageQuoteManager::getInstance()->readFormParameters();
     // polls
     if ($this->canCreatePoll()) {
         PollManager::getInstance()->readFormParameters();
     }
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     // quotes
     MessageQuoteManager::getInstance()->readFormParameters();
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['fileSubject'])) {
         $this->fileSubject = StringUtil::trim($_POST['fileSubject']);
     }
     if (isset($_POST['tags']) && is_array($_POST['tags'])) {
         $this->tags = ArrayUtil::trim($_POST['tags']);
     }
     if (isset($_POST['teaser'])) {
         $this->teaser = StringUtil::trim($_POST['teaser']);
     }
     if (!empty($_POST['uploadID'])) {
         $this->uploadID = intval($_POST['uploadID']);
         $this->fileUpload = new FileUpload($this->uploadID);
     }
     if (isset($_POST['website'])) {
         $this->website = StringUtil::trim($_POST['website']);
     }
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['draft'])) {
         $this->draft = (bool) $_POST['draft'];
     }
     if (isset($_POST['participantCanInvite'])) {
         $this->participantCanInvite = (bool) $_POST['participantCanInvite'];
     }
     if (isset($_POST['participants'])) {
         $this->participants = StringUtil::trim($_POST['participants']);
     }
     if (isset($_POST['invisibleParticipants'])) {
         $this->invisibleParticipants = StringUtil::trim($_POST['invisibleParticipants']);
     }
     // quotes
     MessageQuoteManager::getInstance()->readFormParameters();
 }
 /**
  * @see	\wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['enableDelayedPublication']) && WCF::getSession()->getPermission('user.news.canCreateEntryWithoutModeration')) {
         $this->enableDelayedPublication = intval($_POST['enableDelayedPublication']);
     }
     if (isset($_POST['publicationDate'])) {
         $this->publicationDate = $_POST['publicationDate'];
     }
     if (isset($_POST['tags']) && is_array($_POST['tags'])) {
         $this->tags = ArrayUtil::trim($_POST['tags']);
     }
     if (isset($_POST['isFeatured'])) {
         $this->isFeatured = intval($_POST['isFeatured']);
     }
     // quotes
     MessageQuoteManager::getInstance()->readFormParameters();
     // polls
     if ($this->canCreatePoll()) {
         PollManager::getInstance()->readFormParameters();
     }
 }
 /**
  * @see    \wcf\form\IForm::readFormParameters()
  */
 public function readFormParameters()
 {
     parent::readFormParameters();
     if (isset($_POST['tags']) && is_array($_POST['tags'])) {
         $this->tags = ArrayUtil::trim($_POST['tags']);
     }
     if (isset($_POST['teaser'])) {
         $this->teaser = StringUtil::trim($_POST['teaser']);
     }
     if (isset($_POST['website'])) {
         $this->website = StringUtil::trim($_POST['website']);
     }
     if (isset($_POST['username'])) {
         $this->username = StringUtil::trim($_POST['username']);
     }
 }