In vbulletin my template not show in head

my plugin load in “showthread_complete” and it’s code is:

global $pagenumber, $perpage, $totalposts, $pagetitle, $threadinfo;

$totalpages = ceil($totalposts / $perpage);
$templater = vB_Template::create('opengraph_inshowthread');
$templater->register('pagenumber', $pagenumber);
$templater->register('totalposts', $totalposts);
$templater->register('perpage', $perpage);
$templater->register('totalpages', $totalpages);
$templater->register('pagetitle', $pagetitle);
$templater->register('pagedescription', $threadinfo['description']);
$template_hook['headinclude_bottom_css'] .= $templater->render();

and “opengraph_inshowthread” template code is:

<meta property="og:title" content="{vb:raw pagetitle} - page {vb:raw pagenumber} of {vb:raw totalpages} pages" />

But nothing adds to head. how to add my template to head?
I need to point out that I can not load the plugin in the “parse_template”. Because the page number and other variable is not recognized in “parse_template”.
and How can I use “{vb:rawphrase thread.title}” in my template?

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.