
{extends file='page.htm'}

{block name="main"}
	<h2>Chart</h2>
	
		{$lastScore = -1}
		{$position = 0}
	
	<ul class="">
		{while $user = $userSearch->nextResult()}
			{if $user->getCachedScore() != $lastScore}
				{$lastScore = $user->getCachedScore()}
				{$position = $position + 1}
			{/if}
			<li>
				<div class="position">{$position}</div>
				<div class="user">{$user->getName()|escape}</div>
				<div class="score">{$user->getCachedScore()|escape}</div>
			</li>
		{/while}	
	</ul>
	
{/block}





{extends file='page.htm'}

{block name="main"}
	<h2>Chart</h2>
	
		{$lastScore = -1}
		{$position = 0}
	
	<ul class="userScoreChart">
		{while $user = $userSearch->nextResult()}
			{if $user->getCachedScore() != $lastScore}
				{$lastScore = $user->getCachedScore()}
				{$position = $position + 1}
			{/if}
			<li class="{cycle values="alternate,"}">
				<div class="position">{$position}</div>
				<div class="user">{$user->getName()|escape}</div>
				<div class="score">{$user->getCachedScore()|escape}</div>
			</li>
		{/while}	
	</ul>
	
{/block}




Add classes so we can actually do something in the CSS!
Add classes so we can actually do something in the CSS!
