My mistake, i mean in header not sidebar sorry.
I need get the numbers globally in header and my portal blog software both.
<xen:container var="$onlineUsers">{$onlineUsers.total}</xen:container>
{xen:number $onlineUsers}
And how is possible the call this counts in another php blog software ?Add this to the sidebar_online_users template:
Code:<xen:container var="$onlineUsers">{$onlineUsers.total}</xen:container>
You can then call it in the PAGE_CONTAINER template using:
Code:{xen:number $onlineUsers}
It's really going to require custom development or an add-on to make it available everywhere.
echo '<dl class="pairsJustified discussions"><dt>Discussions:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['discussions'] ) . '</dd></dl>';
echo '<dl class="pairsJustified messages"><dt>Messages:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['messages'] ) . '</dd></dl>';
echo '<dl class="pairsJustified messages"><dt>Currently Online:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['total_online_users'] ) . '</dd></dl>';
/** @var $countersModel XenForo_Model_Counters */
$countersModel = XenForo_Model::create( 'XenForo_Model_Counters' );
$total_counts = $countersModel->getBoardTotalsCounter();
echo '<div class="stats">';
echo '<dl class="pairsJustified discussions"><dt>Discussions:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['discussions'] ) . '</dd></dl>';
echo '<dl class="pairsJustified messages"><dt>Messages:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['messages'] ) . '</dd></dl>';
echo '<dl class="pairsJustified members"><dt>Members:</dt><dd>' . XenForo_Locale::numberFormat( $total_counts['users'] ) . '</dd></dl>';
We use essential cookies to make this site work, and optional cookies to enhance your experience.