loyals-online / silverstripe-tinymce4

BSD 3-Clause "New" or "Revised" License
11 stars 6 forks source link

Support for SS 3.4 #7

Open faloude opened 8 years ago

faloude commented 8 years ago

The module doesn't seem to work on 3.4 (3.4.1 to be specific).

gavro commented 8 years ago

@faloude I'm currently using it with the latest SS 3.4.x-dev install (framework: 4c7ba73, cms: 147181e) without any problems. Could you give me some more details? Are you mixing&matching HtmlEditorField/CustomHtmlEditorField and/or $db-field HTMLText/CustomHTMLText.

You need to use "Custom*", otherwise it'll break.

faloude commented 8 years ago
class MyObject extends DataObject {

private static $db = array(
    'CustomContent' => 'CustomHTMLText'
);

public function getCMSFields() {
    $fields = new FieldList(new TabSet('Root'));

    $fields->addFieldToTab('Root.Main', $contentField = CustomHTMLEditorField::create('CustomContent', 'Content')->setRows(10));
    return $fields;

}`

The field label "Content" is there, but the tinymce block is missing completely

faloude commented 8 years ago

Also, permission on tiny_mce_gzip.php is set to 644. Tried 777 just to be sure, no effect.

helenclarko commented 8 years ago

Same issue here.

Using 3.4.1 within an XAMPP install.

The Custom Content text shows up, but no TinyMCE4 Editor. Interestingly, the content block doesn't show either. I tried to remove the content block and only add the CustomHTMLEditorField, but this failed too.