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

📄 myqamatchmate.jsp.svn-base

📁 用手机浏览的一个类似于聊天室 博克 homepage 等 对这方面有 兴趣的朋友 有所帮助的
💻 SVN-BASE
📖 第 1 页 / 共 2 页
字号:
<!--------------------------------------------------------------------------------------------------------------
*@目敲霸烙 娄茫扁 
*@Author : 弥眠岿 (2008-6-06)
*@Images : 其捞瘤 救俊 甸绢啊绰 捞固瘤
	1) bg_01.png - 抛捞喉 弥惑窜 硅版捞固瘤(仟弗祸)
--------------------------------------------------------------------------------------------------------------->
<%@ page import='java.io.*,java.text.*,java.util.Date,java.util.Vector, javax.servlet.http.HttpSession,java.sql.*, com.entaz.lib.db.*, com.entaz.relay.net.*' contentType='text/html;charset=euc-kr'%>
<%@ include file="../imgpath.jsp"%>
<%@ include file="../common_func.jsp"%>
<%@ include file="../makeKOR.jsp"%>
<%

	/***********************************************************************
	
	@ Page Description
	 	霸烙 皋牢 其捞瘤
	
	@ Parameter

	***********************************************************************/

	/*------------------------------------------------------------------------------------------------------
	+	扁夯 颇扼固磐
	-------------------------------------------------------------------------------------------------------*/	
	String mphone= request.getParameter("mphone");
	
	String gphone= request.getParameter("gphone");
	
	String name= java.net.URLDecoder.decode(makeKOR(request.getParameter("name")));
	
	String ox[] = new String[5];
	
	String qa[] = new String[5];
	
	String qidx[]=new String [5];
	
	/*------------------------------------------------------------------------------------------------------
	+	傈开 函荐
	-------------------------------------------------------------------------------------------------------*/
	long Guest_phone = 0;
	
	int Attention_point = 0;
	
	String nickname = "";
	
	int sex =0;
	
	int year =0;
	
	int nyear =0;
	
	int age =0;
	
	int Match_point = 0;
	
	double answercount =0.0;
	
	int cont1 =0;
	
	double allcont =0.0;
	
	int starAttentionfull =0;
	
	int starAttentionemp = 0;
	
	int starMatchfull =0;
	
	int starMatchemp =0;
	
	double percent =0;
	
	String[] title =new String[5];
	
	String[] quizidx = new String[5];
	
	int flag =0;
	
	int idx = 0;
 	
     /*------------------------------------------------------------------------------------------------------
	+	DB 包访 函荐
	-------------------------------------------------------------------------------------------------------*/
	PreparedStatement pstmt = null;
	
	Connection con = null;
	
	Statement stmt = null;
	
	ResultSet rs = null;
	
	String query1 = null;

	
	
	try
	{

	/*------------------------------------------------------------------------------------------------
	 *		DB 目池记
	 -------------------------------------------------------------------------------------------------*/
	%><%@ include file="../getConnection.jsp"%><%
	/*------------------------------------------------------------------------------------------------
	 *
	 -------------------------------------------------------------------------------------------------*/
	    for(int i=0;i<5;i++)
	    {
	      if(request.getParameter("ox"+i)!=null){
	      	
	     
	      ox[i]=request.getParameter("ox"+i);
	      
	      qa[i] = request.getParameter("qa"+i);
	    
	      qidx[i] = request.getParameter("qidx"+i);

	     query1="insert into GT_LUCKY_QUIZ_MYLOG (Quiz_idx,title,answer,phonenum,Guest_phone)"+
	                  "values(?,?,?,?,?)";
	                  
	     pstmt= con.prepareStatement(query1);
	     
	     pstmt.setInt(1,Integer.parseInt(qidx[i]));
	     
	     pstmt.setString(2,qa[i]);
	     
	     pstmt.setInt(3,Integer.parseInt(ox[i]));
	     
	     pstmt.setLong(4,Long.parseLong(mphone));
	    
	     pstmt.setLong(5,Long.parseLong(mphone));
	     
	     pstmt.executeUpdate();
	     
	     pstmt.close();
	     
	    }
	    
	 }
	 
	/*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩
	 -------------------------------------------------------------------------------------------------*/
	 query1 = "select  top 1 Guest_phone,Attention_point from GT_LUCKY_ATTENTION_POINT where phonenum in("+
	                " select distinct Guest_phone from gt_lucky_quiz_mylog where phonenum =?) "+" order by Attention_point desc";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
	 {
	  Guest_phone = rs.getLong("Guest_phone");

	  Attention_point = rs.getInt("Attention_point");
	  
	 }
	 starAttentionfull = Attention_point/4;
	 
	 starAttentionemp = (Attention_point%4)/2;
	 
	 rs.close();
	 
	 pstmt.close();
	 
	 /*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩狼 扁夯 沥焊 
	 -------------------------------------------------------------------------------------------------*/
	 query1="select nickname,sex,year from gt_user_info where phonenum = '0"+Guest_phone+"'";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
	 {
	  nickname = rs.getString("nickname");
	  
	  sex = rs.getInt("sex");
	  
	  year = rs.getInt("year");
	  
	 }
	 
	 rs.close();
	 
	 pstmt.close();
	 
	 Calendar calendar=Calendar.getInstance();
	 
	 nyear=calendar.get(Calendar.YEAR);
	 
	 age = nyear-year;
	 
	  /*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩狼 概莫档 
	 -------------------------------------------------------------------------------------------------*/
	 query1="select Match_point from GT_LUCKY_MATCH_POINT where phonenum =? and Guest_phone = ?";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 pstmt.setLong(2,Guest_phone);
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
	 {
	  
	  Match_point = rs.getInt("Match_point");
	  
	 }
	starMatchfull = Match_point/4;
	
	starMatchemp = (Match_point%4)/2;
	
	 rs.close();
	 
	 pstmt.close();

	  /*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩 沥翠 荐  
	 -------------------------------------------------------------------------------------------------*/
	 query1 = " select count(a.idx) answercount from gt_lucky_quiz_mylog a,gt_lucky_quiz_mylog c"+
		  " where  a.quiz_idx=c.quiz_idx and a.answer = c.answer"+
		  " and a.phonenum =? and a.guest_phone =?"+
		  " and c.phonenum =?"+" and c.guest_phone =?";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 pstmt.setLong(2,Guest_phone);
	 
	 pstmt.setLong(3,Long.parseLong(mphone));
	 
	 pstmt.setLong(4,Long.parseLong(mphone));
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
	 {
	  
	  answercount = rs.getInt("answercount");
	  
	 }
	
	 rs.close();
	 
	 pstmt.close();

	 /*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩 翠函  荐  
	 -------------------------------------------------------------------------------------------------*/
	 query1="select  count(idx) as allcont  from GT_LUCKY_QUIZ_MYLOG where phonenum =? and Guest_phone =? ";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 pstmt.setLong(2,Guest_phone);
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
     {
       allcont = rs.getInt("allcont");
     }	 
	 
	 percent = (answercount/allcont) * 100;
	  
	 /*------------------------------------------------------------------------------------------------
	 *	唱客 嘎绰 荤恩 荐  
	 -------------------------------------------------------------------------------------------------*/
	 query1="select count(distinct Guest_phone)as cont1  from gt_lucky_quiz_mylog where phonenum =?";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 rs = pstmt.executeQuery();
	 
	 if(rs.next())
	 {
	   cont1 = rs.getInt("cont1");
	 }
	 
	 rs.close();
	 
	 pstmt.close();
	 
     /*------------------------------------------------------------------------------------------------
	 *	 钱绢焊瘤 臼篮 巩力  
	 -------------------------------------------------------------------------------------------------*/
	query1 = "select distinct top 5  a.title,a.idx from GT_LUCKY_QUIZ a,GT_LUCKY_QUIZ_MYLOG b where a.idx = b.Quiz_idx"+
                   " and a.flag = 1 and b.Quiz_idx not in(select quiz_idx from GT_LUCKY_QUIZ_MYLOG where Guest_phone =?)"+
                   " order by a.idx desc";
	 
	 pstmt = con.prepareStatement(query1);
	 
	 pstmt.setLong(1,Long.parseLong(mphone));
	 
	 rs = pstmt.executeQuery();
	 
	 for(int i=0;rs.next();i++)
	 {
	   title[i] = rs.getString("title");
	   
	   quizidx[i] = rs.getString("idx");
	   
	   flag = i+1;
	 }
	 
	 rs.close();
	 
	 pstmt.close();
	 
	%>
	<html>
<head>
	<link href="../mobile.css" rel="stylesheet" type="text/css">
	<title>权 > <%=name %>丛狼 迄乔包府 > 家匡皋捞飘 > 龙巩措翠</title>
</head>
<body>

<!--剧侥
  <tr>
     <td>
          <table width="240" border="0" cellspacing="0" cellpadding="0">
             <tr>  
  	    <td></td>
      	   </tr>
          </table>
     </td>
  </tr>
-->
<form name="form1" action="MYQAmatchMate.jsp" method="post">
<input type="hidden" name="name" value="<%=java.net.URLEncoder.encode(name)%>"/>
<input type="hidden" name="mphone" value="<%=mphone%>"/>
<input type="hidden" name="gphone" value="<%=gphone%>"/>


<table width="240" border="0" cellspacing="0" cellpadding="0">
	<!--鸥捞撇 矫累-->
	<tr>
		<td>
			<table width="240" border="0" cellspacing="0" cellpadding="0">
				<tr>
					<td colspan="2" height="2" bgcolor="#c789ff"></td>
				</tr>
				<tr>
					<td width="10" height="15" bgcolor="#9819e9"></td>
					<td height="15" bgcolor="#9819e9"><font color="#ffffff">龙巩措翠 钱绢焊扁</font></td>
				</tr>
				<tr>
					<td colspan="2" height="2" bgcolor="#c789ff"></td>
				</tr>
				<tr>
					<td colspan="2" height="1" bgcolor="#9819e9"></td>
				</tr>
			</table>
		</td>
	</tr>
	<!--鸥捞撇 场-->

	<!--咯归 矫累-->
	<tr>
		<td height="8"></td>
	</tr>
	<!--咯归 场-->
<%if(nickname!=""){%>
	<!--唱客 嘎绰 荤恩甸 冠胶 矫累-->
	<tr>
		<td>
			<table width="240"  bgcolor="#ecaaff" border="0" cellspacing="0" cellpadding="0">
				<tr>
					<td colspan="3" height="3"></td>
				</tr>
				<tr>
					<td width="3"></td>

⌨️ 快捷键说明

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