Location: PHPKode > projects > Enigma > Enigma2/Enigma2_Install/Themes/Enigma/portal/ResourceManagement.template.php
<?php

function template_rim_above()
{
	global $context;

	echo '
<div class="tborder">
	<table border="0" cellpadding="2" cellspacing="1" width="100%">
		<tr>
			<th class="titlebg" width="100%">', $context['main_title'], '</th>
		</tr><tr>
			<td class="windowbg2" width="100%">';
}

function template_rim_below()
{
	global $context;

	echo '</td>
		</tr>
	</table>
</div><br />';

}

function template_rim_test()
{
	global $context, $scripturl;

	echo theme_linktree(), '<br />';

	echo '<a href="', $scripturl, '?module=ResourceIndexManagement;sa=recount">Recount totals</a><br />';
	echo '<a href="', $scripturl, '?module=ResourceIndexManagement;sa=optimize">Optimize Tables</a>';
}

function template_rim_recount()
{
	global $context;

	echo theme_linktree(), '<br />';

	if ($context['stoped'])
	{
		echo '<p><font color="#FF0000"><b>Process stoped becouse the default PHP time limit (30) was about to be reached<br />Please select unlimited time recount to finish recounting!</b></font></p>';
		echo '
<div class="tborder">
	<table border="0" cellpadding="2" cellspacing="3" width="100%">
		<tr>
			<td class="catbg" width="100%">Update incomplete!</td>
		</tr>';
	}
	else
	{
		echo '
<div class="tborder">
	<table border="0" cellpadding="2" cellspacing="1" width="100%">
		<tr>
			<td class="catbg" width="100%">Update Complete!</td>
		</tr>';
	}

	echo '<tr>
			<td class="windowbg" width="100%">Sections ', $context['CIDSEC'], '</td>
		</tr><tr>
			<td class="windowbg" width="100%">Catagories	', $context['CIDCAT'], '</td>
		</tr><tr>
			<td class="windowbg" width="100%">in ', $context['recount_time'], ' Seconds, with ',$context['db_rim_After'],' queries.</td>
		</tr>
	</table>
</div><br />
	<script language="JavaScript" type="text/javascript">
	<!--
		var current_module = false;

		function shrinkModule(mode, module)
		{
			document.getElementById(module).style.display = mode ? "none" : "";
			current_module = mode;
		}
	// -->
	</script>';

	while (list ($key, $secblah) = each ($context['this_title']))
	{
		echo '
<div class="tborder">
	<table border="0" cellpadding="2" cellspacing="1" width="100%">
		<tr>
			<td class="titlebg" width="100%" colspan="2"><b><a href="javascript:void(0);" onclick="shrinkModule(!current_module, \'', $secblah['ID_SEC'], '\'); return false;" class="ext">', $secblah['Title'], '</a></b>, ',$context['sec_count'][$secblah['ID_SEC']],'  Categories.</td>
		</tr>
	<tbody style="display: none;" id="', $secblah['ID_SEC'], '">
		<tr>
			<th class="catbg" width="100%">Title</th>
			<th class="catbg" width="100%">Count</th>
		</tr>';

		foreach ($context['subs'][$secblah['ID_SEC']] AS $subzero)
		{
			echo '<tr>
			<td class="windowbg2" width="100%">',$subzero['scat'],'</td>
			<td class="windowbg" width="100%" style="text-align: center;">',$subzero['count'],'</td>
		</tr>';
		}

		echo '
	</tbody>
	</table>
</div>
<br />';
	}
}

function template_rim_listcats()
{
	global $context;
}
?>
Return current item: Enigma