<?php
/*
	[UCenter Home] (C) 2007-2008 Comsenz Inc.
	$Id: paihang.php 10954 2009-01-12 05:26:27Z liguode $
*/

include_once('../common.php');

//是否关闭站点
checkclose();

//是否公开
if(empty($_SCONFIG['networkpublic'])) {
	checklogin();
}
$list = array();
if ( !empty($_SGLOBAL['supe_uid']) )
{
	$query = $_SGLOBAL['db']->query("SELECT lian FROM ".tname('site_game')." WHERE uid=".intval($_SGLOBAL['supe_uid']));
	while ($value = $_SGLOBAL['db']->fetch_array($query)) {
		$list[] = $value;
	}
	if ( $list )
	{
		$count = $_SGLOBAL['db']->result($_SGLOBAL['db']->query("SELECT COUNT(*) FROM ".tname('site_game')."  WHERE lian > ".$list[0]['lian']), 0);
		echo '排名： '.($count+1).'  	分数：'.$list[0]['lian'];
	}
	else
	{
		echo "暂无排行";
	}
}
else
{
	echo "没有登陆，暂无排行";
}
?>