No.Is there a hook for the board closed message?
What is it for?Is there a hook for the board closed message?
before and after raw template in pagenode_container would be epic, that way most customizations can be global, rather than per page node, we now have to use per page node call backs.
<div class="sectionFooter">
<ul class="listInline bulletImplode">
<xen:hook start>
<li><a href="{xen:link search/member, '', 'user_id={$user.user_id}'}">{xen:phrase find_all_content_by_x, 'name={$user.username}'}</a></li>
<li><a href="{xen:link search/member, '', 'user_id={$user.user_id}', 'content=thread'}">{xen:phrase find_all_threads_by_x, 'name={$user.username}'}</a></li>
<xen:hook end>
</ul>
</div>
<div class="section">
<h3 class="textHeading">{xen:phrase interact}</h3>
<div class="primaryContent">
<div class="pairsColumns contactInfo">
<dl>
<dt>{xen:phrase content}:</dt>
<dd><ul>
<li><a href="{xen:link search/member, '', 'user_id={$user.user_id}'}">{xen:phrase find_all_content_by_x, 'name={$user.username}'}</a></li>
<li><a href="{xen:link search/member, '', 'user_id={$user.user_id}', 'content=thread'}">{xen:phrase find_all_threads_by_x, 'name={$user.username}'}</a></li>
</ul></dd>
</dl>
<xen:hook name="thread_view_qr_before" params="{xen:array 'thread={$thread}'}" />
<xen:if is="{$canQuickReply}">
<link rel="xenforo_template" type="text/html" href="quick_reply.html">
<xen:set var="$formAction">{xen:link 'threads/add-reply', $thread}</xen:set>
<xen:set var="$lastDate">{$lastPost.post_date}</xen:set>
<xen:set var="$showMoreOptions">1</xen:set>
</link>
</xen:if>
<xen:hook name="thread_view_qr_before" params="{xen:array 'thread={$thread}'}" />
<xen:if is="{$canQuickReply}">
<link rel="xenforo_template" type="text/html" href="quick_reply.html">
<xen:set var="$formAction">{xen:link 'threads/add-reply', $thread}</xen:set>
<xen:set var="$lastDate">{$lastPost.post_date}</xen:set>
<xen:set var="$showMoreOptions">1</xen:set>
</link>
</xen:if>
<xen:hook name="thread_view_qr_after" params="{xen:array 'thread={$thread}'}" />
Can we get a hook or two in sidebar_online_users? Would be useful for add-ons to add sidebar blocks. Or am I missing something? lol
public static function templateHook($name, &$contents, array $params, XenForo_Template_Abstract $template)
{
if ($name == 'page_container_sidebar') {
$options = XenForo_Application::get('options');
$limit = $options->ragtek_NM_counter;
$latestUsers = XenForo_Model::create('Ragtek_FW_Latest')->getLatestUsers($limit);
$params = array(
'latestUsers' => $latestUsers
);
$t = $template->create('ragtekNM', $params)->render();
$search = '<!-- end block: sidebar_online_users -->';
$contents = str_replace($search, $search . $t, $contents);
}
}
Well, look at that. Do you know if there's a way to inject something under "Staff Online Now"?There are some hooks forum_list_sidebar, sidebar_visitor_panel_stats,page_container_sidebar (that's the one i'm using for all my add-ons and what you're searching for^^)
will add an block UNDER the online users (http://xenforo.com/community/threads/ragtek-newest-members-sidebarblock.14906/ )PHP:public static function templateHook($name, &$contents, array $params, XenForo_Template_Abstract $template) { if ($name == 'page_container_sidebar') { $options = XenForo_Application::get('options'); $limit = $options->ragtek_NM_counter; $latestUsers = XenForo_Model::create('Ragtek_FW_Latest')->getLatestUsers($limit); $params = array( 'latestUsers' => $latestUsers ); $t = $template->create('ragtekNM', $params)->render(); $search = '<!-- end block: sidebar_online_users -->'; $contents = str_replace($search, $search . $t, $contents); } }
yep.Well, look at that. Do you know if there's a way to inject something under "Staff Online Now"?
Well, look at that. Do you know if there's a way to inject something under "Staff Online Now"?
if you do it that way, make sure that you replace the used remark hook in YOUR template (At the very bottom of your template) as well so that others can hook in...
$search = '<!-- end block: sidebar_online_users -->';
$contents = str_replace($search, $search . $t, $contents);
We use essential cookies to make this site work, and optional cookies to enhance your experience.