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

Fixed Can not create editor in AdminCP

Discussion in 'Resolved Bug Reports' started by Milano, Feb 13, 2014.

  1. Milano

    Milano Well-Known Member

    I got this error when trying to create editor in Admin CP
    Code:
    Template Errors: editor_ui.css
        Invalid argument supplied for foreach() in xxx\library\XenForo\Template\Abstract.php(265) : eval()'d code, line 237: 236: ';
    237: foreach ($customBbCodes AS $bbCodeTag => $bbCode)
     
  2. Amaury

    Amaury Well-Known Member

    Have you tried with add-ons disabled?
     
  3. tajhay

    tajhay Well-Known Member

    nothing to do with the error. try reading the actual error first please.
     
    Liam W likes this.
  4. cclaerhout

    cclaerhout Well-Known Member

    The admin css renderer is missing some code. Here's a patch:
    Class: XenForo_ViewAdmin_CssInternal

    Search:
    PHP:
        $templateParams = array(
           
    'displayStyles' => array(),
           
    'smilieSprites' => array(),
           
    'xenOptions' => XenForo_Application::get('options')->getOptions(),
           
    'dir' => $this->_params['dir'],
           
    'pageIsRtl' => ($this->_params['dir'] == 'RTL')
         );
    Replace with:
    PHP:
        if (XenForo_Application::isRegistered('bbCode'))
         {
           
    $bbCodeCache XenForo_Application::get('bbCode');
         }
         else
         {
           
    $bbCodeCache XenForo_Model::create('XenForo_Model_BbCode')->getBbCodeCache();
         }

         
    $templateParams = array(
           
    'displayStyles' => array(),
           
    'smilieSprites' => array(),
           
    'xenOptions' => XenForo_Application::get('options')->getOptions(),
           
    'customBbCodes' => !empty($bbCodeCache['bbCodes']) ? $bbCodeCache['bbCodes'] : array(),
           
    'dir' => $this->_params['dir'],
           
    'pageIsRtl' => ($this->_params['dir'] == 'RTL')
         );
     
    D.O.A., Milano and Liam W like this.
  5. Mike

    Mike XenForo Developer Staff Member

    I've added the extra data for the CSS.
     
    Milano likes this.

Share This Page