weixin_33722405 2013-05-26 09:32 采纳率: 0%
浏览 36

Joomla Ajax编辑器

Hi I am still struggling with a Joomla editor question:

Can I have two or more text editors on one page (I think yes)

If so how can I put a second one on the page using AJAX.

I can get the ajax etc working but the part of the script to put the editor on screen results in an error:

HP Fatal error: Call to undefined method JDocumentRaw::addCustomTag()

code snippet for the called ajax code is:

    $document =& JFactory::getDocument();
    $editor = JFactory::getEditor();
    $params = array( 'smilies'=> '0' ,
                 'style'  => '1' ,  
                 'layer'  => '0' , 
                 'table'  => '0' ,
                 'clear_entities'=>'0'
                 );
    $obj->{'postsHolder'} .=  $editor->display( 'desc', '', '400', '400', '20', '20', false, $params );

Thanks for any help you can give me

  • 写回答

1条回答 默认 最新

  • 三生石@ 2013-05-27 02:53
    关注

    Without seeing the code that is triggering the error, it is tough to be sure, but I believe the issue is with how you are adding your custom tag. With the above close, you can do this with:

    $document->addCustomTag($tag);
    

    See http://docs.joomla.org/JDocumentHTML/addCustomTag

    评论

报告相同问题?