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

How to use a template for a $variable?

Discussion in 'XenForo Development Discussions' started by Marcus, Oct 23, 2013.

  1. Marcus

    Marcus Well-Known Member

    In a class I want to make the $message variable more beautiful, so I want to use a "custom_template" to style the variable. Template custom_template:
    My code would be
    $viewParams = array('message' $message);
    $message XenForo_Template('custom_template'$viewParams);
    Do you know how I could get the code working? The class is within event notice_fire, so I do not have access to any parent class. Thank you !

Share This Page