Re: tinymceの編集画面が表示されない

2015年3月26日 at 13:53

修正しました。

オリジナルのスタイルをメニューに追加したいために
デフォルトのcontentブロックのeditor_config.phpをオーバーライドしていました。

以前は

<script language="javascript">
tinyMCE.init({
〜略〜
entity_encoding: 'raw',
style_formats: [
{title: 'responsiv table', inline: 'table', classes: 'responsivetable'}, //スタイル追加
{title: 'facility title', block: 'h2', classes: 'ttlbr'}, //スタイル追加
],
<?php if (is_object($theme)) { ?>
content_css : "<?php echo $theme->getThemeEditorCSS()?>",
<?php } ?>
<?php if(EDITOR_LANGUAGE != "en"){ ?>
translate_mode : true,
language : "<?php echo EDITOR_LANGUAGE?>",
<?php
}
〜略〜
</script>

としていたのを

if(isset($theme) && is_object($theme)) {
$textEditorOptions['content_css'] = $theme->getThemeEditorCSS();
$style= array(
array('title' => 'responsiv table','inline' => 'table','classes' => 'responsivetable'), //スタイル追加
array('title' => 'facility title','block' => 'h2','classes' => 'ttlbr'), //スタイル追加
);
$textEditorOptions['style_formats'] = $style;
}
$textEditorOptions = Loader::helper('tinymce')->getOptions($textEditorOptions);
?><script language="javascript" type="text/javascript">
tinyMCE.init(<?php echo Loader::helper('json')->encode($textEditorOptions); ?>);
</script>

とすることで解決しました。
ありがとうございました。