在mangento后台调用wysiwyg编辑器

在mangento后台调用操蛋的wysiwyg编辑器:

1.在头部加载TincyMCE

  protected function _prepareLayout() {
    parent::_prepareLayout();
    if (Mage::getSingleton('cms/wysiwyg_config')->isEnabled()) {
        $this->getLayout()->getBlock('head')->setCanLoadTinyMce(true);
    }
2.
$fieldset->addField('content', 'editor', array(
    'name'      => 'content',
    'label'     => Mage::helper('demomodule')->__('Content'),
    'title'     => Mage::helper('demomodule')->__('Content'),
    'style'     => 'height:15em',
    'config'    => Mage::getSingleton('cms/wysiwyg_config')->getConfig(),
    'wysiwyg'   => true,
    'required'  => false,
));
作者:冯亮
         
能力有限,水平一般。如有错误,欢迎指正
原文地址:https://www.cnblogs.com/fengliang/p/3766311.html