WPLib::register_template PHP Method

register_template() static public method

Register a template
static public register_template ( string $template, string | boolean $called_class = false )
$template string
$called_class string | boolean
    static function register_template($template, $called_class = false)
    {
        if (!$called_class) {
            $called_class = get_called_class();
        }
        $module_name = self::get_module_name($called_class);
        self::$_templates[$module_name][$template] = self::maybe_make_abspath_relative(static::get_template_dir($template));
    }