<?php


function buy_shop_show( )
{
		if ( !$_SESSION['accountName'])
		{
				return "<div class=\"act_btn\"><a href=\"../UserCenter/Login.php\" class=\"bt_but c_1_g mr10 tips\"><u></u>请登录...</a></div>";
		}
		$str1 = "<div class=\"act_btn\"><div> 角色：<select name=\"serverandrole\" id=\"role3\" style=\"width:115px;\">";
		$str3 = "</select><input type=\"checkbox\" name=\"roleChk\" value=\"1\"></div>\r\n\t<INPUT type=\"submit\"  value=\"购买选中物品\" />\r\n\t\t</div>";
		$i = 0;
		for ( ;	$i < 1;	++$i	)
		{
			include_once "../configuration/config.inc.php";
				if ( !mysql_select_db( "aionx_gs") )
				{

						return "选择角色数据库失败!请检查的数据库配置信息!";
				}
				mysql_query( "SET @@character_set_connection=utf8,@@character_set_results=utf8,@@character_set_client=utf8" );
				$playerinfo = mysql_query( "SELECT * FROM players WHERE account_name='".$_SESSION['accountName']."'" );
				$playernum = mysql_num_rows( $playerinfo );
				$ii = 0;
				for ( ;	$ii < $playernum;	++$ii	)
				{
						$playerrow = mysql_fetch_array( $playerinfo );
						$str1 = $str1."<option value=\"".$playerrow[id]."\">".$playerrow[name]."</option>";
				}
		}
		include( "config.php" );
		return $str1 .= $str3;
}


?>
