* Added users online list pagination
* Added support for embedded youtube playlists
* Scaled embedded youtube videos to maximum width
+* `\wcf\form\AbstractCaptchaForm`: added parameter to force captcha usage for registered users.
#### CMS
public $captchaObjectTypeName = CAPTCHA_TYPE;
/**
- * true if recaptcha is used
+ * true if captcha is used
* @var boolean
*/
public $useCaptcha = true;
+ /**
+ * true to force captcha usage
+ * @var boolean
+ */
+ public $forceCaptcha = false;
+
/**
* @inheritDoc
*/
* @inheritDoc
*/
public function readData() {
- if (!WCF::getUser()->userID && $this->useCaptcha && $this->captchaObjectTypeName) {
+ if ((!WCF::getUser()->userID || $this->forceCaptcha) && $this->useCaptcha && $this->captchaObjectTypeName) {
$this->captchaObjectType = CaptchaHandler::getInstance()->getObjectTypeByName($this->captchaObjectTypeName);
if ($this->captchaObjectType === null) {
throw new SystemException("Unknown captcha object type with name '".$this->captchaObjectTypeName."'");