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

Why is this listener deaf: XenForo_BbCode_TextWrapper ?

Discussion in 'XenForo Development Discussions' started by Marcus, Aug 4, 2013.

  1. Marcus

    Marcus Well-Known Member

    I can listen to XenForo_BbCode_Parser with the Load Class listener. But the same listener is absolutely deaf to XenForo_BbCode_TextWrapper :(

      public static function LoadClass($class, array &$extend)
         switch ($class)
           case 'XenForo_BbCode_Parser':ZEND_DEBUG::dump("Parser Listener");
             $extend[] = 'Wb_BbCode_Parser';
           case 'XenForo_BbCode_TextWrapper':ZEND_DEBUG::dump("Wb_BbCode_TextWrapper Listener");
             $extend[] = 'Wb_BbCode_TextWrapper';
  2. xf_phantom

    xf_phantom Well-Known Member

    XenForo isn't using the proxy system to load XenForo_BbCode_TextWrapper
  3. Marcus

    Marcus Well-Known Member

    Tried three hours doing that on a sunny sunday :D Do you think it's going to be part of the proxy system in the future?

    Do you have any idea how to use the Parser:: parse() function for getting the BBCode Tree of my messages? The idea behind is, that I want to create a database table (post_id, bbcode_tag, bbcode_option, bbcode_children) and parse() is *the* function for doing so. I could not access Parse:: parse() from ControllerPublic, so I thought about hooking into TextWrapper as I have access there to $content_id.
    Last edited: Aug 4, 2013
  4. Marcus

    Marcus Well-Known Member

    As the listener is deaf for the TextWrapper, I created my own MyTextWrapper. It works now.

Share This Page