1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Add a editor in AdminCP

Discussion in 'XenForo Development Discussions' started by Fuhrmann, Dec 13, 2011.

  1. Fuhrmann

    Fuhrmann Well-Known Member

    Is there a way to add an editor using wysiwyg in the Admin Control Panel?

    I already tried this:

    PHP:
    $this->_params['additionalInfo'] = XenForo_ViewPublic_Helper_Editor::getEditorTemplate(
                
    $this'message','',
                array(
    'editorId' =>    'ctrl_additional_info''height' => '150px''templateName' => 'editor')
            );
    But when I {xen:raw} only appear a textarea. No controls, anything.
     
    Digital Doctor and principia like this.
  2. Morgain

    Morgain Well-Known Member

    Sounds useful.
     
    Fuhrmann likes this.
  3. Fuhrmann

    Fuhrmann Well-Known Member

    Well, it looks like this is not possible.
     
  4. Morgain

    Morgain Well-Known Member

    Thinking again - I don't exactly understand Fuhrmann.
    Is this to edit things IN the admin area?
    Or is it to add a WYSWYG editor to the frontend somewhere?
     
  5. Fuhrmann

    Fuhrmann Well-Known Member

    It is an editor like the 'reply to a thread' but in the admin area. It will be used in a addon to add additional information.
     
  6. Robbo

    Robbo Well-Known Member

    Anything is possible. You just need to find out how. You are trying to grab a public template from within the ACP, this might be your issue and you might just have to do the same stuff in the admin controllers? Just a guess.
     
  7. Fuhrmann

    Fuhrmann Well-Known Member

    Thanks for the reply. Yes. You just gave me an ideia!
     
  8. Fuhrmann

    Fuhrmann Well-Known Member

    Actually there is already the admin template of the editor. I'm using this:

    PHP:
    $this->_params['additionalInfo'] = XenForo_ViewPublic_Helper_Editor::getEditorTemplate(
                
    $this'message','',
                array(
    'editorId' =>    'ctrl_additional_info''height' => '150px''templateName' => 'editor')
            );
    And then in the admin template this:

    Code:
    {xen:raw $additionalInfo}
    But this only show me a simple text area.
     
  9. Fuhrmann

    Fuhrmann Well-Known Member

  10. Fuhrmann

    Fuhrmann Well-Known Member

    LiquidPro likes this.

Share This Page