hi.
i've been trying to make JCE (or a similar editor) work in the Extra Fields' textarea field.
i've made the following change :
in
case 'textarea' :
if ($active[1])
{
if ($required)
{
$attributes = 'class="k2ExtraFieldEditor k2Required"';
}
else
{
$attributes = 'class="k2ExtraFieldEditor"';
}
}
$output = '<textarea name="K2ExtraField_'.$extraField->id.'" id="K2ExtraField_'.$extraField->id.'" rows="10" cols="40" '.$attributes.'>'.htmlspecialchars($active[0], ENT_QUOTES, 'UTF-8').'</textarea>';
break;
i replaced the section of
$output = '<textarea name="K2ExtraField_'.$extraField->id.'" id="K2ExtraField_'.$extraField->id.'" rows="10" cols="40" '.$attributes.'>'.htmlspecialchars($active[0], ENT_QUOTES, 'UTF-8').'</textarea>';
break;
with
$editor =& JFactory::getEditor();
$output = '<textarea name="K2ExtraField_'.$extraField->id.'" $editor->display("K2ExtraField_".$extraField->id."", '.$attributes.'>'.htmlspecialchars($active[0], ENT_QUOTES, 'UTF-8'), '550', '400', '60', '20', false)'</textarea>';
but this gave me syntax errors (obviously).
so i changed to
$editor =& JFactory::getEditor();
$output = $editor->display("K2ExtraField_".$extraField->id."", $active[0], '550', '400', '60', '20', false);
this gives me enlarged editing areas but still no JCE editor.
i dont mind having it hardcoded, but i realy need a better editor than what comes by default on the Extra Field's textarea NicEditor.
any suggestions?