/** * @see wcf\page\IPage::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_POST['updates']) && is_array($_POST['updates'])) { $this->updates = $_POST['updates']; } }
/** * @see wcf\page\IPage::readParameters() */ public function readParameters() { parent::readParameters(); if (file_exists(WCF_DIR . 'acp/masterPassword.inc.php')) { require_once WCF_DIR . 'acp/masterPassword.inc.php'; } }
/** * @see wcf\form\IForm::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['id'])) { $this->packageID = intval($_REQUEST['id']); if ($this->packageID != 0) { try { $this->package = new Package($this->packageID); } catch (SystemException $e) { throw new IllegalLinkException(); } } } }
/** * @see wcf\page\IPage::readParameters() */ public function readParameters() { parent::readParameters(); // get type id $this->typeID = ClipboardHandler::getInstance()->getObjectTypeID('com.woltlab.wcf.user'); if ($this->typeID === null) { throw new SystemException("clipboard item type 'com.woltlab.wcf.user' is unknown."); } // get user ids $users = ClipboardHandler::getInstance()->getMarkedItems($this->typeID); if (!isset($users['com.woltlab.wcf.user']) || empty($users['com.woltlab.wcf.user'])) { throw new IllegalLinkException(); } // load users $this->userIDs = array_keys($users['com.woltlab.wcf.user']); $this->users = $users['com.woltlab.wcf.user']; }
/** * @see wcf\page\IPage::readParameters() */ public function readParameters() { parent::readParameters(); $this->activeMenuItem = $this->action == 'all' ? 'wcf.acp.menu.link.user.mail' : ($this->action == 'group' ? 'wcf.acp.menu.link.group.mail' : 'wcf.acp.menu.link.user.management'); }
/** * @todo This whole page is carzy, it's manipulating the requested page, but RequestHandler does not work this way * @see wcf\page\IPage::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['loginUsername'])) { $this->loginUsername = $_REQUEST['loginUsername']; } if (isset($_REQUEST['loginPassword'])) { $this->loginPassword = $_REQUEST['loginPassword']; } if (isset($_REQUEST['saveAuthData'])) { $this->saveAuthData = intval($_REQUEST['saveAuthData']); } if ($this->packageUpdateServerID == 0 && isset($_REQUEST['packageUpdateServerID'])) { $this->packageUpdateServerID = intval($_REQUEST['packageUpdateServerID']); } if (!empty($_REQUEST['requestedPage']) || !empty($_REQUEST['requestedForm']) || !empty($_REQUEST['requestedAction'])) { // get update server $updateServer = new PackageUpdateServer($this->packageUpdateServerID); if (!$updateServer->packageUpdateServerID) { throw new IllegalLinkException(); } // update update server if ($this->saveAuthData) { $updateServerEditor = new PackageUpdateServerEditor($updateServer); $updateServerEditor->update(array('loginUsername' => $this->loginUsername, 'loginPassword' => $this->loginPassword)); } // save auth data in session $authData = array('authType' => 'Basic', 'loginUsername' => $this->loginUsername, 'loginPassword' => $this->loginPassword); // session data $packageUpdateAuthData = WCF::getSession()->getVar('packageUpdateAuthData'); if ($packageUpdateAuthData === null) { $packageUpdateAuthData = array(); } $packageUpdateAuthData[$this->packageUpdateServerID] = $authData; WCF::getSession()->register('packageUpdateAuthData', $packageUpdateAuthData); // remove form=PackageUpdateAuth unset($_REQUEST['form'], $_GET['form'], $_POST['form']); // set page/form/action if (!empty($_REQUEST['requestedPage'])) { $_POST['page'] = $_REQUEST['requestedPage']; } else { if (!empty($_REQUEST['requestedForm'])) { $_POST['form'] = $_REQUEST['requestedForm']; } else { $_POST['action'] = $_REQUEST['requestedAction']; } } // remove requestedPage... unset($_REQUEST['requestedPage'], $_REQUEST['requestedForm'], $_REQUEST['requestedAction']); // start request handler /** * TODO: This is not working anymore, find a solution! */ global $packageDirs; RequestHandler::handle(ArrayUtil::appendSuffix(!empty($packageDirs) ? $packageDirs : array(WCF_DIR), 'lib/acp/')); exit; } }