Shorty1968
Erfahrenes Mitglied
Hallo ich bin bei der Entwicklung meines Plugins auf Folgenden Fehler gestossen.
Die Zeile 373 sieht so aus.
10 Zeilen vor dem Code:
10 Zeilen nach dem Code:
Ich komme nicht dahinter was der Fehler ist?
Code:
Parse error: syntax error, unexpected T_VARIABLE, expecting T_FUNCTION in /var/www/vhosts/wbb-support.eu/httpdocs/testforum/wbb4/tutorials/lib/form/TutorialsAddForm.class.php on line 373
Code:
$categoryTree = new TutorialsCategoryNodeTree('wcf2tutorialssystem.category');
PHP:
/**
* @see \wcf\page\IPage::readData()
*/
public function readData() {
parent::readData();
// get label groups
$labelGroupIDs = TutorialsCategoryCache::getInstance()->getLabelGroups($this->category->categoryID);
if (!empty($labelGroupIDs)) {
$this->labelGroups = LabelHandler::getInstance()->getLabelGroups($labelGroupIDs);
}
return $this->$labelGroups;
}
PHP:
$this->categoryList = $categoryTree->getIterator();
$this->categoryList->setMaxDepth(0);
if (empty($_POST)) {
// multilingualism
if (!empty($this->availableContentLanguages)) {
if (!$this->languageID) {
$language = LanguageFactory::getInstance()->getUserLanguage();
$this->languageID = $language->languageID;
}
if (!isset($this->availableContentLanguages[$this->languageID])) {
$languageIDs = array_keys($this->availableContentLanguages);
$this->languageID = array_shift($languageIDs);
}
}
// set default publication and archivation date
$dateTime = DateUtil::getDateTimeByTimestamp(TIME_NOW);
$dateTime->setTimezone(WCF::getUser()->getTimeZone());
$this->publicationDate = $this->archivingDate = $dateTime->format('c');
}
// add breadcrumbs
TUTORIALSCore::getInstance()->setBreadcrumbs();
}