⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 play_gamename_back.jsp

📁 用手机浏览的一个类似于聊天室 博克 homepage 等 对这方面有 兴趣的朋友 有所帮助的
💻 JSP
📖 第 1 页 / 共 2 页
字号:






<%@ page import='java.io.*,java.text.*,java.util.Date,java.util.Vector, java.sql.*, com.entaz.lib.db.*, com.entaz.relay.net.*' contentType='text/html;charset=euc-kr'%>
<%@ include file="../imgpath.jsp"%>

<%	//焙	己龋
	response.setHeader("cache-control","no-cache");
	response.setHeader("expires","0");
	response.setHeader("pragma","no-cache");

	Connection con = null;
	PreparedStatement pstmt=null;
	Statement stmt = null;
	ResultSet rs = null;
	ResultSet pageset = null;
	
	String mphone = request.getParameter("mphone");
	String gphone = request.getParameter("gphone");

	
	String query1=null, query2=null, goGameDetel=null;

	String goUserHome="";
	String phonenum=null, nickname=null;
	String strDel=null, strShow=null;
	String boardname=null;
	String game_title, game_text, game_img_path, game_path;
	int gamerank_idx =0, gamerank_score = 0, rankCnt=2, game_score=0;

	// 其捞瘤 备泅 眠啊 函荐 
	int pagesize=4;  // 茄其捞瘤寸 10俺 免仿拱

	// 傈开 函荐肺 急攫.. 其捞瘤 备泅 何盒俊 犁荤侩
	int pageNUM=1;    // 其捞瘤 锅龋
	int pagecount=1; // 其捞瘤 肮荐 瘤沥 函荐

	int absolutepage=1;  // 例措 困摹 其捞瘤 锅龋
    int dbcount=0;   //  DB 救俊 臂 肮荐 历厘 函荐
	int isNoPage=0;	//茄俺档 绝蠢衬.. 绝栏搁0, 乐栏搁1
	
	int game_idx = Integer.parseInt(request.getParameter("game_idx"));
	
	//game_title = request.getParameter("game_title");
	
	String gameTable = "GT_gamerank_"+game_idx;//盔夯

	//朝楼 包访	
	Timestamp di_date=null;
	Date today = new Date();
	SimpleDateFormat timeform;
	timeform = new SimpleDateFormat("yy斥/mm岿/dd老");

	//di_date 		= 	rs.getTimestamp(3); //朝楼啊廉坷扁
	//<%=timeform.format(di_date);		//朝楼 谎府扁

	int myScore=0,myClover=0;
	
	int firstIs = 0;	//1困啊 粮犁窍绰啊
	String firstPhone = "";//1困 迄锅龋
	String firstIntro = "";//1困 磊扁家俺
	int firstScore = 0;//1困 痢荐
	String firstNickname = "";//1困 喊疙
	String firstUserHome = "";

	//霸烙墨其
	String strTemp = "";
	String cafe_idx[] = new String[3];
	String cafe_name[] = new String[3];
	String cafe_Link[] = new String[3];
	int cafeCount = 0;

	//霸烙瘤侥堡厘
	int kthema_idx[] = new int[3];//
	String kthema_title[] = new String[3];
	String kthema_Link[] = new String[3];//瘤侥堡厘 官肺啊扁 傅农
	int kthemaCount=0;
	
try
{



	//=========================== 傍烹函券累诀 : 2008-01-21 ===========================

	/**
	 * 公丰霸烙鸥款 矫胶袍痢八 棺 喉发蜡历 八免
	 * 
	 * @ date		?8-01-21
	 * @ version			1.2.0
	 */

	String SYSTEM_PARAMETER_SET = "?mphone="+request.getParameter("mphone")+"&gphone="+request.getParameter("mphone");
	String SYSTEM_PHONE_NUMBER = request.getParameter("mphone");

	// 矫胶袍 痢八 眉农
	//
	if(IS_SYSTEM_CHECK)
	{
		if( ! IS_TESTER_MODE )
		{
			response.sendRedirect(url_path+"/system_notice.jsp"+SYSTEM_PARAMETER_SET);
			return;
		}
	}
	// DB 楷搬捞 登瘤 臼阑 锭, 救郴芒栏肺 捞悼
	//
	con = DBConnector.getConnection(db_name);
	if( con == null )
	{
		response.sendRedirect(url_path+"/system_notice2.jsp"+SYSTEM_PARAMETER_SET);
		return;
	}
	// 矫胶袍痢八 吝捞咯档 抛胶磐绰 荤侩啊瓷
	//
	if( IS_TESTER_MODE )
	{
		boolean isTester = DBConnector.chkTester( con, SYSTEM_PHONE_NUMBER );
		if( ! isTester )
		{
			response.sendRedirect(url_path+"/system_notice.jsp"+SYSTEM_PARAMETER_SET);
			return;
		}
	}
	// 喉发蜡历牢瘤 眉农, 
	//
	boolean isBlackUser = DBConnector.chkBlackList( con, SYSTEM_PHONE_NUMBER );
	if( isBlackUser ) 
	{
		response.sendRedirect(url_path+"/bad_member.jsp"+SYSTEM_PARAMETER_SET);
		return;
	}

	//=========================== 傍烹函券累诀 : 2008-01-21 ===========================




	// 其捞瘤 函荐蔼 荤侩窍扁 困秦辑 DB俊辑 眠免窍绰 何盒
	stmt = con.createStatement(); 
	
	//霸烙墨其 啊廉坷扁
	query1="select Top 3 cafe_idx, cafe_name from GT_cafe where category_idx=5 order by cafe_idx desc";
	rs=stmt.executeQuery(query1);
	while(rs.next())
	{
		strTemp = rs.getString(2);
		strTemp =( (strTemp.length()>17) ? strTemp.substring(0,17)+"..." : strTemp );
		cafe_idx[cafeCount]=rs.getString(1);
		cafe_Link[cafeCount]=url_path+"/cafe/cafe_master.jsp?mphone="+mphone+"&gphone="+gphone+"&cafe_idx="+cafe_idx[cafeCount];
		cafe_name[cafeCount]="<a href='"+cafe_Link[cafeCount]+"'>"+strTemp+"</a>";
		cafeCount++;
	}

	//霸烙瘤侥 啊廉坷扁	
	query1="select Top 3 kthema_idx, kthema_title from GT_kthema where kthema_category_1=3 and kthema_level=0 order by kthema_idx desc";
	rs=stmt.executeQuery(query1);
	kthema_idx[0] = kthema_idx[1] = kthema_idx[2] = 0;
	while(rs.next())
	{
		strTemp = rs.getString(2);
		strTemp =( (strTemp.length()>17) ? strTemp.substring(0,17)+"..." : strTemp );
		kthema_idx[kthemaCount]=rs.getInt(1);
		kthema_Link[kthemaCount]= url_path+"/kthema/kthema_question_view.jsp?mphone="+mphone+"&gphone="+gphone+"&questionidx="+kthema_idx[kthemaCount];//霸烙包访 瘤侥堡厘 傅农
		kthema_title[kthemaCount]= "<a href='"+kthema_Link[kthemaCount]+"'>"+strTemp+"</a>";
		kthemaCount++;	
	}

	//1困狼 沥焊 啊廉柯促	//0626
	String str = "select Top 1 gamerank_idx, GT_user_info.phonenum, GT_user_info.nickname, gamerank_score, gamerank_date, GT_user_info.intro";
	str = str + " from "+gameTable+" inner join GT_user_info on GT_user_info.phonenum="+gameTable+".phonenum order by gamerank_score desc , gamerank_date desc";
	
	pstmt = con.prepareStatement(str);
	rs = pstmt.executeQuery();
	if(rs.next())
	{
		firstIs = 1;
		firstPhone = rs.getString(2); 
		firstNickname = rs.getString(3);
		firstIntro = rs.getString(6);
		firstScore = rs.getInt(4);
		firstUserHome = url_path+"/mypage/my_confirm.jsp?mphone="+mphone+"&gphone="+firstPhone;	
	}
	
	
	//霸烙狼 力格苞 咆胶飘甫 啊廉柯促.
	query1 = "select game_title, game_text, game_img_path, game_path from GT_game where game_new=2 and game_idx="+game_idx;
	rs = stmt.executeQuery(query1);
	rs.next();
	
	game_title=rs.getString(1);
	game_text=rs.getString(2);
	game_img_path=rs.getString(3);
	game_path=rs.getString(4);

	query1 = "select count(gamerank_idx) from "+gameTable;
	pageset = stmt.executeQuery(query1);

	if(pageset.next()){
		dbcount = pageset.getInt(1);  // 臂 醚 肮荐
		pageset.close();
	}

	if(dbcount%pagesize == 0)
		pagecount = dbcount/(pagesize); // 醚 其捞瘤荐 备窍扁
	else
		pagecount = dbcount/(pagesize)+1; // 醚 其捞瘤荐 备窍扁


	if(request.getParameter("pageNUM")!=null)
	{
		pageNUM=Integer.parseInt(request.getParameter("pageNUM"));//瘤沥等 其捞瘤 焊咯林扁
		absolutepage=(pageNUM-1)*pagesize+1;
	}

	str = "select Top 2 gamerank_idx, phonenum, nickname, gamerank_score, gamerank_date";
	str = str + " from "+gameTable;
	
	if(firstIs == 1)	//1困绰 哗绊 
		str = str + " where phonenum!="+firstPhone + " ";
	str = str + "  order by gamerank_score desc , gamerank_date desc";	//0626

	rs = stmt.executeQuery(str);	
	if(!rs.next()) // 蔼捞 绝阑锭
	{
		isNoPage = 1;
		pagesize=0;
	}
	else         // 蔼捞 乐阑锭	//rs.absolute(absolutepage);
	{				
		for(int s=0; s<absolutepage-1; s++)
			rs.next();
	}
%>


<html>
<head>
	<title>::: 霸烙 ::: 霸烙窍扁 :::</title>
</head>
<body>
	<!--// page title section //-->
	<table width="240" border="0" cellspacing="0" cellpadding="0">
		<tr height="3">
			<td width="8" bgcolor="#C789FF"></td>
			<td width="232" bgcolor="#C789FF"></td>
		</tr>

		<tr height="13">
			<td width="8" bgcolor="#9819E9"></td>
			<td width="232" bgcolor="#9819E9" align="left" valign="middle">
				<font color="#FFFFFF"><%=game_title%></font>
			</td>
		</tr>

		<tr height="3">
			<td width="8" bgcolor="#C789FF"></td>
			<td width="232" bgcolor="#C789FF"></td>
		</tr>

		<tr height="1">
			<td width="8" bgcolor="#9819E9"></td>
			<td width="232" bgcolor="#9819E9"></td>
		</tr>

		<tr height="10">
			<td width="8"></td>
			<td width="232"></td>
		</tr>
	</table>

	<!--// start to play this game //-->
	<!--// #1. title //-->
	<table width="240" border="0" cellspacing="0" cellpadding="0">
		<tr height="15">
			<td width="240" align="center" valign="middle">
				<font color="#FCF2FF">≮</font>&nbsp;<font color="#F6D6FF">≮</font>&nbsp;<font color="#ECAAFF">≮</font>&nbsp;<font color="#9819E9"><%=game_title%></font>&nbsp;<font color="#ECAAFF">≮</font>&nbsp;<font color="#F6D6FF">≮</font>&nbsp;<font color="#FCF2FF">≮</font>
			</td>
		</tr>
	</table>

	<!--// #2. game-image and description //-->
	<table width="240" border="0" cellspacing="0" cellpadding="0">
		<tr height="3">
			<td width="3"></td>
			<td width="90"></td>
			<td width="3"></td>
			<td width="141"></td>
			<td width="3"></td>
		</tr>

		<tr height="70">
			<td width="3"></td>
			<td width="90">
				<img src="<%=img_path%>images/296img/296_game/<%=game_img_path%>" width="90" height="70" border="0">
			</td>
			<td width="3"></td>
			<td width="141">
				<table width="141" border="0" cellspacing="0" cellpadding="0">
					<tr height="3">
						<td width="3"></td>
						<td width="85"></td>
						<td width="53"></td>
					</tr>
					<tr height="47">
						<td width="141" colspan="3" align="left" valign="top">
							<font color="#616667"><%=game_text%></font>
						</td>
					</tr>
					
					<tr height="2">
						<td width="3"></td>
						<td width="85"></td>
						<td width="53"></td>
					</tr>
				</table>
			</td>
			<td width="3"></td>
		</tr>

		<tr height="3">
			<td width="3"></td>
			<td width="90"></td>
			<td width="3"></td>
			<td width="141"></td>
			<td width="3"></td>
		</tr> 
	</table>

<!-- 霸烙矫累, 档框富 滚瓢 -->
	<table width="240" border="0" cellspacing="0" cellpadding="0">
		<tr height="3"><td colspan="5"></td></tr>
		<tr height="18">
			<td width="34"></td>
			<td width="85" bgcolor="#C789FF" align="center" valign="middle"><a href="<%=url_path%>/ranking/start_game.jsp?game_idx=<%=game_idx%>&mphone=<%=mphone%>&gphone=<%=gphone%>"><font color="#FFFFFF">霸烙矫累窍扁</font></a></td>
			<td width="2"></td>
			<td width="85" bgcolor="#C789FF" align="center" valign="middle"><a href="<%=url_path%>/ranking/game_help.jsp?game_idx=<%=game_idx%>&mphone=<%=mphone%>&gphone=<%=gphone%>"><font color="#FFFFFF">档框富</font></a></td>
			<td width="34"></td>
		</tr>
		<tr height="5"><td colspan="5"></td></tr>
	</table>
<!-- 霸烙矫累, 档框富 滚瓢 场 -->

	<!--// game ranking! - best ranker's avata, scores //-->
<%
	if(firstIs == 1) //茄疙档 绝促搁 弊妨瘤瘤 臼酒具 茄促.
	{
%>
	<table width="240" border="0" cellspacing="0" cellpadding="0">
		<tr height="3">
			<td width="3" bgcolor="#ECAAFF"></td>
			<td width="234" bgcolor="#ECAAFF"></td>
			<td width="3" bgcolor="#ECAAFF"></td>
		</tr>

		<tr height="5">
			<td width="3" bgcolor="#ECAAFF"></td>
			<td width="234"></td>
			<td width="3" bgcolor="#ECAAFF"></td>
		</tr>

		<tr height="18">
			<td width="3" bgcolor="#ECAAFF"></td>
			<td width="234">
				<table width="234" border="0" cellspacing="0" cellpadding="0">
					<tr height="18">
						<td width="94" align="right" valign="middle">
							<font color="#FFE0E4">≮</font>&nbsp;<font color="#FF99B3">≮</font>&nbsp;<font color="#FF6587">≮</font>&nbsp;
						</td>
						<td width="46" align="center" valign="middle">
							<img src="<%=img_path%>images/296img/296_game/no1.png" width="45" height="18" border="0">
						</td>
						<td width="94" align="left" valign="middle">
							&nbsp;<font color="#FF6587">≮</font>&nbsp;<font color="#FF99B3">≮</font>&nbsp;<font color="#FFE0E4">≮</font>
						</td>
					</tr>
				</table>
			</td>
			<td width="3" bgcolor="#ECAAFF"></td>
		</tr>

		<tr height="5">
			<td width="3" bgcolor="#ECAAFF"></td>
			<td width="234"></td>
			<td width="3" bgcolor="#ECAAFF"></td>
		</tr>

		<tr height="205">
			<td width="3" bgcolor="#ECAAFF"></td>
			<td width="234">
				<table width="234" border="0" cellspacing="0" cellpadding="0">
					<tr height="1">
						<td width="54"></td>
						<td width="126" bgcolor="#D3E2E5"></td>
						<td width="54"></td>
					</tr>

					<tr height="203">
						<td width="54"></td>
						<td width="126" align="center" valign="middle">
							<img src="<%=ava_path%>display_movata.jsp?mphone=<%=firstPhone%>" width="126" height="203" border="0">
						</td>
						<td width="54"></td>
					</tr>

					<tr height="1">
						<td width="54"></td>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -