/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (WCF::getUser()->userID || WCF::getSession()->getVar('captchaDone')) { $this->useCaptcha = false; } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['userID'])) { $this->userID = intval($_REQUEST['userID']); } if (isset($_REQUEST['objectID'])) { $this->objectID = intval($_REQUEST['objectID']); } if (isset($_REQUEST['objectType'])) { $this->objectType = $_REQUEST['objectType']; } if ($this->objectID != 0 && $this->objectType != '') { $this->object = Warning::getWarningObjectByID($this->objectType, $this->objectID); if ($this->object === null) { throw new IllegalLinkException(); } } // get user $this->user = new UserSession($this->userID); if (!$this->user->userID) { throw new IllegalLinkException(); } if ($this->user->getPermission('admin.user.infraction.canNotBeWarned')) { throw new NamedUserException(WCF::getLanguage()->getDynamicVariable('wcf.user.infraction.error.canNotBeWarned', array('user' => $this->user))); } if ($this->object !== null) { // search existing warning $sql = "SELECT\t*\n\t\t\t\tFROM\twcf" . WCF_N . "_user_infraction_warning_to_user\n\t\t\t\tWHERE\tpackageID = " . PACKAGE_ID . "\n\t\t\t\t\tAND objectID = " . $this->objectID . "\n\t\t\t\t\tAND objectType = '" . escapeString($this->objectType) . "'\n\t\t\t\t\tAND userID = " . $this->userID; $warning = new UserWarning(null, WCF::getDB()->getFirstRow($sql)); if ($warning->warningID) { throw new NamedUserException(WCF::getLanguage()->getDynamicVariable('wcf.user.infraction.error.alreadyReported', array('warning' => $warning))); } } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_GET['userID'])) { $this->userID = intval($_GET['userID']); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (LOGIN_USE_CAPTCHA && !WCF::getSession()->getVar('captchaDone')) { $this->useCaptcha = true; } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (!empty($_REQUEST['url'])) { $this->url = $_REQUEST['url']; } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['q'])) { $this->query = StringUtil::trim($_REQUEST['q']); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (isset($_REQUEST['category'])) { $this->activeCategory = $_REQUEST['category']; } $this->user = WCF::getUser(); }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); // get available conditions $this->availableRuleConditionTypes = PMRule::getAvailableRuleConditionTypes(); // get available actions $this->availableRuleActions = PMRule::getAvailableRuleActions(); }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['messageID'])) { $this->messageID = intval($_REQUEST['messageID']); } if (isset($_REQUEST['userID'])) { $this->userID = intval($_REQUEST['userID']); } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['u'])) { $this->userID = intval($_REQUEST['u']); } if (isset($_REQUEST['k'])) { $this->lostPasswordKey = StringUtil::trim($_REQUEST['k']); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (isset($_REQUEST['optionID'])) { $this->optionID = intval($_REQUEST['optionID']); } $this->userOption = new UserOptionEditor($this->optionID); if (!$this->userOption->optionID || $this->userOption->editable > 3 || $this->userOption->visible > 3) { throw new IllegalLinkException(); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (isset($_REQUEST['smileyID'])) { $this->smileyID = intval($_REQUEST['smileyID']); } $this->smiley = new SmileyEditor($this->smileyID); if (!$this->smiley->smileyID) { throw new IllegalLinkException(); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (isset($_REQUEST['sponsortalkID'])) { $this->sponsortalkID = intval($_REQUEST['sponsortalkID']); } $this->entry = new ContestSponsortalkEditor($this->sponsortalkID); if (!$this->entry->sponsortalkID || !$this->entry->isEditable()) { throw new IllegalLinkException(); } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_GET['allianceID'])) { $this->allianceID = intval($_GET['allianceID']); } if (!isset($_GET['allianceID']) || $this->allianceID != WCF::getUser()->ally_id) { require_once WCF_DIR . 'lib/system/exception/IllegalLinkException.class.php'; throw new IllegalLinkException(); } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['groupID'])) { $this->groupID = intval($_REQUEST['groupID']); } $this->group = new Group($this->groupID); if (!$this->group->groupID) { throw new IllegalLinkException(); } if (isset($_REQUEST['pmSuccess'])) { $this->pmSuccess = intval($_REQUEST['pmSuccess']); } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['groupID'])) { $this->groupID = intval($_REQUEST['groupID']); } $this->group = new Group($this->groupID); if (!$this->group->groupID || $this->group->groupType != 6 && $this->group->groupType != 7) { throw new IllegalLinkException(); } // check if an application for this group already exist if (GroupApplicationEditor::getApplication(WCF::getUser()->userID, $this->group->groupID)) { throw new IllegalLinkException(); } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (WCF::getUser()->avatarID) { $this->avatar = new AvatarEditor(WCF::getUser()->avatarID); $this->avatarType = $this->avatar->userID ? 'user' : 'selected'; } else { if (MODULE_GRAVATAR == 1 && WCF::getUser()->gravatar) { $this->avatar = new Gravatar(WCF::getUser()->gravatar); $this->avatarType = 'gravatar'; } } if (!isset($_REQUEST['userAvatar']) && $this->avatarType == 'selected' || isset($_REQUEST['userAvatar']) && !$_REQUEST['userAvatar']) { $this->userAvatar = false; } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); if (isset($_REQUEST['pmID'])) { $this->pmID = intval($_REQUEST['pmID']); } if (isset($_REQUEST['forwarding'])) { $this->forwarding = intval($_REQUEST['forwarding']); } if (isset($_REQUEST['reply'])) { $this->reply = intval($_REQUEST['reply']); } if (isset($_REQUEST['replyToAll'])) { $this->replyToAll = intval($_REQUEST['replyToAll']); } if ($this->replyToAll == 1) { $this->reply = 1; } if (isset($_REQUEST['userID'])) { $this->userID = intval($_REQUEST['userID']); } // change default values for pm form if (isset($_GET['recipients'])) { $this->recipients = StringUtil::trim($_GET['recipients']); } if (isset($_GET['blindCopies'])) { $this->blindCopies = StringUtil::trim($_GET['blindCopies']); } // get private message if ($this->pmID) { $this->pm = new PMEditor($this->pmID); // check permission if (!WCF::getUser()->userID || !$this->pm->hasAccess()) { throw new PermissionDeniedException(); } $this->pm->markAsRead(); if (!$this->reply && !$this->forwarding && !$this->pm->isDraft) { throw new IllegalLinkException(); } if ($this->reply && !$this->pm->userID) { throw new IllegalLinkException(); } } }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_REQUEST['postID'])) { $this->postID = intval($_REQUEST['postID']); } $this->post = new PostEditor($this->postID); $this->thread = new ThreadEditor($this->post->threadID); $this->board = new BoardEditor($this->thread->boardID); $this->thread->enter($this->board); if (!WCF::getUser()->userID) { throw new PermissionDeniedException(); } // check whether this post was already reported $sql = "SELECT \tpostID\n\t\t\tFROM\twbb" . WBB_N . "_post_report\n\t\t\tWHERE\tpostID = " . $this->postID; $row = WCF::getDB()->getFirstRow($sql); if (isset($row['postID'])) { throw new NamedUserException(WCF::getLanguage()->get('wbb.report.error.alreadyReported')); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); // get application if (isset($_REQUEST['applicationID'])) { $this->applicationID = intval($_REQUEST['applicationID']); } $this->application = new GroupApplicationEditor($this->applicationID); if (!$this->application->applicationID) { throw new IllegalLinkException(); } // get group $this->group = new Group($this->application->groupID); $this->groupID = $this->group->groupID; if ($this->application->applicationStatus > 0) { $this->reason = $this->application->reason; } // check permission if (!GroupApplicationEditor::isGroupLeader(WCF::getUser(), $this->application->groupID)) { throw new PermissionDeniedException(); } }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); // get user if (isset($_REQUEST['userID'])) { $this->userID = intval($_REQUEST['userID']); require_once WBB_DIR . 'lib/data/user/AbstractWBBUserSession.class.php'; $this->user = new AbstractWBBUserSession($this->userID); if (!$this->user->userID) { throw new IllegalLinkException(); } require_once WCF_DIR . 'lib/data/user/group/Group.class.php'; if (!Group::isAccessibleGroup($this->user->getGroupIDs())) { throw new PermissionDeniedException(); } } // active permission if (isset($_REQUEST['permissionName'])) { $this->permissionName = $_REQUEST['permissionName']; } $this->readPermissionSettings(); }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); $this->version = $this->getVersion(); for ($i = ICSHE_MINYEAR; $i <= ICSHE_MAXYEAR; $i++) { $this->years[] = $i; } if (empty($_POST['fromYear'])) { $this->fromYear = date('Y'); } if (empty($_POST['toYear'])) { $this->toYear = date('Y'); } if (empty($_POST['country'])) { $this->country = 'DE'; } /* if (!WCF::getUser()->userID || !WCF::getUser()->getPermission('user.calendar.canUseCalendar')) { require_once (WCF_DIR . 'lib/system/exception/PermissionDeniedException.class.php'); throw new PermissionDeniedException(); } */ }
/** * @see Form::readParameters() */ public function readParameters() { parent::readParameters(); // get boards from cache $this->boards = WCF::getCache()->get('board', 'boards'); }
/** * @see Page::readParameters() */ public function readParameters() { parent::readParameters(); }
/** * @see Page::readParameters() */ public function readParameters() { AbstractForm::readParameters(); }