Salutations,
I am trying to use the DataObjectDecorator to add some fields to the UserDefinedForm. I need to add a textbox for a Sidebar. When I use this code in my /code/ directory
<?php
class CustomForm extends DataObjectDecorator{
function extraField(){
return array(
'db' => array(
'Sidebar' => 'HTMLText'
),
'has_one' => array(
),
);
}
public function updateCMSFields(FieldSet $fields) {
$fields->push(new HTMLEditorField('Sidebar','Sidebar'));
}
}
?>
As well, I added the appropriate code onto the _config.php.
When I go into the CMS, the Sidebar field is anchored to the bottom of my editor window. It seems like the CMS is adding the field, but not into the Content->Main fieldset.
How can I add this field to a different tab, or change it's order so it's not anchored to the bottom?