/** * renderValidationJS * TEMPORARY SOLUTION to 'override' original renderValidationJS method * with custom XoopsEditor's renderValidationJS method */ function renderValidationJS() { if (is_object($this->editor) && $this->isRequired()) { if (method_exists($this->editor, 'renderValidationJS')) { $this->editor->setName($this->getName()); $this->editor->setCaption($this->getCaption()); $this->editor->_required = $this->isRequired(); $ret = $this->editor->renderValidationJS(); return $ret; } else { parent::renderValidationJS(); } } return ''; }
/** * XoopsFormDhtmlTextArea::renderValidationJS() * * @return bool|string */ function renderValidationJS() { if ($this->htmlEditor && is_object($this->htmlEditor) && method_exists($this->htmlEditor, 'renderValidationJS')) { if (!isset($this->htmlEditor->isEnabled) || $this->htmlEditor->isEnabled) { return $this->htmlEditor->renderValidationJS(); } } return parent::renderValidationJS(); }