thats looks very helpful though it still not what i need .
i want to change the <div> tag to <div id="thread_active_users">
actually,
the code in the SHOWTHREAD template is :
and i want to change it with :
Code:
<!-- Refresh Button -->
<vb:if condition="$vbulletin->options[\'active_users_onoff\']">
<button onclick="showUsers()" type="button" style="float:left;"> {vb:rawphrase refresh_button} </button>
</vb:if>
<div id="thread_active_users">
<p>
so i can use what u did and do something like that :
PHP Code:
$find = '<div>' . "\n" . ' <p>';
$replace = " <!-- Refresh Button -->\n";
if ($vbulletin->options['active_users_onoff'])
$replace .= '<button onclick="showUsers()" type="button" style="float:left;"> ' . htmlspecialchars_uni($vbphrase['refresh_button']) . '</button>' . '<div id="thread_active_users">' . "\n" . ' <p>';
// $replace .= $find;
$vbulletin->templatecache['SHOWTHREAD'] = str_replace($find, $replace, $vbulletin->templatecache['SHOWTHREAD']);
though this on the hook showthread_complete doesnt work.
--------------- Added [DATE]1368635293[/DATE] at [TIME]1368635293[/TIME] ---------------
how can i find the right text to find? the compiled version of SHOWTHREAD doesnt help at all...
this is the right part of it i think, but it tells me nothing :
Code:
' . vB_Template_Runtime::parsePhrase("users_browsing_this_thread") . '
' . vB_Template_Runtime::parsePhrase("users_currently_browsing_x_y_z", '' . $totalonline . '', '' . $numberregistered . '', '' . $numberguest . '') . '