这个 我想一次select完 解密数据 不会写循环 那位大哥帮帮忙呀 小弟感谢拉
时间:2010-10-03
来源:互联网
<?
include "../../inc/commonclass.inc";
include "../../inc/common.lib";
include "../../inc/base.inc";
include "../../inc/cdate.lib";
include "../../seoul/inc/left_menu.inc";
include "../../inc/AES_4.class.php";
$aes = new AES($aes_key);
$srace_id = $_GET['userid'];
//焊救鞘夸其捞瘤
$ssl_check=1;
// 肺弊牢登绢乐绰瘤 眉农!(海鸥饶 昏力)
//坷弗硅呈
if(!$srace_id){
echo "
<script>
alert('肺弊牢阑 秦林技夸')
this.location.href='/login/login_page.php';
</script>
";
return;
}
$rec = new OCIclass;
$rec->DBConnect2();
$rec2 = new OCIclass;
$rec2->DBConnect2();
if($menu_id == null)
$menu_id = 1;
$sql ="select name,userid,sid,sid,email,passwd,handphone,sms_f,email_f from srace_user where userid='$srace_id'";
$result = $rec->Fetchone($sql);
$result[2]=substr($aes->decrypt(base64_decode($result[2])),0,6);
$result[3]=substr($aes->decrypt(base64_decode($result[3])),6,7);
$result[4]=$aes->decrypt(base64_decode($result[4]));
$result[6]=$aes->decrypt(base64_decode($result[6]));
print $result[0];
print $result[1];
print $result[4];
print $result[6];
?>
include "../../inc/commonclass.inc";
include "../../inc/common.lib";
include "../../inc/base.inc";
include "../../inc/cdate.lib";
include "../../seoul/inc/left_menu.inc";
include "../../inc/AES_4.class.php";
$aes = new AES($aes_key);
$srace_id = $_GET['userid'];
//焊救鞘夸其捞瘤
$ssl_check=1;
// 肺弊牢登绢乐绰瘤 眉农!(海鸥饶 昏力)
//坷弗硅呈
if(!$srace_id){
echo "
<script>
alert('肺弊牢阑 秦林技夸')
this.location.href='/login/login_page.php';
</script>
";
return;
}
$rec = new OCIclass;
$rec->DBConnect2();
$rec2 = new OCIclass;
$rec2->DBConnect2();
if($menu_id == null)
$menu_id = 1;
$sql ="select name,userid,sid,sid,email,passwd,handphone,sms_f,email_f from srace_user where userid='$srace_id'";
$result = $rec->Fetchone($sql);
$result[2]=substr($aes->decrypt(base64_decode($result[2])),0,6);
$result[3]=substr($aes->decrypt(base64_decode($result[3])),6,7);
$result[4]=$aes->decrypt(base64_decode($result[4]));
$result[6]=$aes->decrypt(base64_decode($result[6]));
print $result[0];
print $result[1];
print $result[4];
print $result[6];
?>
作者: fangzhouy 发布时间: 2010-10-03
<?
include("../inc/common.inc") ;
DBconnect();
if(!$page)$page=0;
if(!$seperate)$seperate=1;
?>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=euc-kr">
</head>
<body bgcolor="#FFFFFF" >
<p align="center"><b>雀盔 府胶飘</b></p>
<div align="center">
<table width="800" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100" align="center">醚 雀盔荐
</td>
<?
$sql="select count(*) from sms_user";
$result=Fetchonerecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<td width="100" align="center">ONLINE雀盔荐
</td>
<?
$sql="select count(*) from sms_user where grade =1";
$result=Fetchonerecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<?
$sql="select count(*) from sms_user where grade =2";
$result=Fetchonerecord($sql);
?>
<td width="100" align="center">OFFLINE雀盔荐
</td>
<td width="50" align="left"><?echo $result[0]?>
</td>
<td width="100" align="center">荐脚啊瓷辑厚胶雀盔荐
</td>
<?
$sql="select count(*) from sms_user where active_flag=1 and smspoint =0";
$result=FetchOneRecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<?
$sql="select count(*) from sms_user where active_flag=1 and smspoint !=0";
$result=FetchOneRecord($sql);
?>
<td width="100" align="center">荐脚啊瓷 蜡丰雀盔荐
</td>
<td width="100" align="left"><?echo $result[0]?>
</td>
</tr>
</table>
<table width="800" border="1" cellspacing="0" cellpadding="0">
<tr bgcolor="#FFCCCC" bordercolor="#33CCCC">
<td width="60">
<div align="center">备盒</div>
</td>
<td width="60">
<div align="center">捞抚</div>
</td>
<td width="92">
<div align="center">酒捞叼</div>
</td>
<td width="97">
<div align="center">荐脚惑怕</div>
</td>
<td width="150">
<div align="center">林刮锅龋</div>
</td>
<td width="134">
<div align="center">荐脚锅龋</div>
</td>
<td width="112">
<div align="center">POINT</div>
</td>
<td width="79">
<div align="center">涝陛犬牢</div>
</td>
</tr>
<?
if($seperate==1){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user ";
$sql_cnt = "select count(*) from sms_user ";
}
else if($seperate==2){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where active_flag=1 and smspoint !=0 ";
$sql_cnt = "select count(*) from sms_user where active_flag=1 and smspoint !=0";
}
else if($seperate==3){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where grade !=1 ";
$sql_cnt = "select count(*) from sms_user where grade != 1";
}
else if($seperate==4){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where active_flag!=1 ";
$sql_cnt = "select count(*) from sms_user where active_flag!=1 ";
}
else {
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where smspoint<=0 ";
$sql_cnt = "select count(*) from sms_user where smspoint<=0 ";
}
// $sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user ";
// $sql_cnt = "select count(*) from sms_user ";
if(strlen($string)){
if($seperate==1){
if($search==1){
$sql.=" where username like '%$string%' order by username";
$sql_cnt.=" where username like '%$string%'";
}
else if($search==2){
$sql.=" where handphone like '%$string%'";
$sql_cnt.=" where handphone like '%$string%'";
}
else {
$sql.=" where userid like '%$string%' order by userid";
$sql_cnt.=" where userid like '%$string%' ";
}
}
else{
if($search==1){
$sql.=" and username like '%$string%' order by username";
$sql_cnt.=" and username like '%$string%'";
}
else if($search==2){
$sql.=" and handphone like '%$string%'";
$sql_cnt.=" and handphone like '%$string%'";
}
else {
$sql.=" and userid like '%$string%' order by userid";
$sql_cnt.=" and userid like '%$string%' ";
}
}
}
else {
$sql.=" order by username";
$sql_cnt.=" order by username";
}
$result=FetchOnerecord($sql_cnt);
$total=$result[0];
Query($sql);
for($i=0;$i<$page*10;$i++)$result=Fetchrecord();
for($i=0;$i<10&&$result=Fetchrecord();$i++){
?>
<tr bgcolor="#FFFFFF" bordercolor="#33CCCC">
<td width="60">
<div align="center"><?if($result[0]==1)echo "沥雀盔";else echo "霖雀盔";?></div>
</td>
<td width="60">
<div align="center"><?if($result[1])echo $result[1];else echo " ";?></div>
</td>
<td width="92">
<div align="center"><?if($result[2])echo $result[2];else echo " "?></div>
</td>
<td width="97">
<div align="center"><?if($result[3]==1)echo "true";else echo "<font color=red>false</font>";?></div>
</td>
<td width="150">
<div align="center"><?if($result[4])echo substr($result[4],0,6)."-".substr($result[4],6,7);else echo " "?></div>
</td>
<td width="134">
<div align="center"><a href="user_view.php?page=<?echo $page?>&search=<?echo $search?>&string=<?echo $string?>&handphone=<?echo $result[5]?>"><?if($result[5])echo $result[5];else echo " "?></a></div>
</td>
<td width="112">
<div align="center"><?if($result[6])echo $result[6];else echo "0";?></div>
</td>
<td width="79">
<div align="center"><a href="./money_list.php?page=<?echo $page?>&search=<?echo $search?>&string=<?echo $string?>&handphone=<?echo $result[5]?>">涝陛犬牢</a></div>
</td>
</tr>
<?
}
?>
</table><br>
<?
//府胶飘狼 其捞瘤锅龋甫 免仿茄促.
//$pcount : 傈眉 饭内靛狼 荐
//$ppage : 免仿且 其捞瘤锅龋
//$row : 茄其捞瘤俊 免仿登绰 饭内靛荐
//$purl : 汗蓖且 林家 ,颇扼固磐 器窃 抗)$purl="kyungjuma1.php?string=$string&mapil=$mapil"
//汗蓖且版快 page颇扼固磐啊 歹 嘿绢辑 泅力 其捞瘤锅龋啊 傈崔等促.
PageList($total,$page,10,"user_list.php?string=$string&search=$search&seperate=$seperate");
?>
<form method="post" action="user_list.php">
<table width="800" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100" align="right"></td>
<td width="30" align="right"><a href="smsadmin.php">Menu</a></td>
<td width="167" align="right">
<select name="seperate">
<option value="1" <?if($seperate==1)echo "selected"?>>傈眉 雀盔</option>
<option value="2" <?if($seperate==2)echo "selected"?>>蜡丰 雀盔</option>
<option value="3" <?if($seperate==3)echo "selected"?>>OFFLINE 雀盔</option>
<option value="4" <?if($seperate==4)echo "selected"?>>荐脚焊幅 雀盔</option>
<option value="5" <?if($seperate==5)echo "selected"?>>器牢飘 绝绰 雀盔</option>
</select>
</td>
<td width="99" align="center">
<select name="search">
<option value="1" <?if($search==1)echo "selected"?>>捞抚</option>
<option value="2" <?if($search==2)echo "selected"?>>荐脚锅龋</option>
<option value="3" <?if($search==3)echo "selected"?>>ID</option>
</select>
</td>
<td width="169">
<input type="text" name="string" size="20" maxlength="20">
</td>
<td width="225">
<input type="submit" value="八祸">
</td>
</tr>
</table>
</form>
<p> </p></div>
</body>
</html>
<?
DBclose();
?>
参考资料
include("../inc/common.inc") ;
DBconnect();
if(!$page)$page=0;
if(!$seperate)$seperate=1;
?>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=euc-kr">
</head>
<body bgcolor="#FFFFFF" >
<p align="center"><b>雀盔 府胶飘</b></p>
<div align="center">
<table width="800" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100" align="center">醚 雀盔荐
</td>
<?
$sql="select count(*) from sms_user";
$result=Fetchonerecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<td width="100" align="center">ONLINE雀盔荐
</td>
<?
$sql="select count(*) from sms_user where grade =1";
$result=Fetchonerecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<?
$sql="select count(*) from sms_user where grade =2";
$result=Fetchonerecord($sql);
?>
<td width="100" align="center">OFFLINE雀盔荐
</td>
<td width="50" align="left"><?echo $result[0]?>
</td>
<td width="100" align="center">荐脚啊瓷辑厚胶雀盔荐
</td>
<?
$sql="select count(*) from sms_user where active_flag=1 and smspoint =0";
$result=FetchOneRecord($sql);
?>
<td width="50" align="left"><?echo $result[0]?>
</td>
<?
$sql="select count(*) from sms_user where active_flag=1 and smspoint !=0";
$result=FetchOneRecord($sql);
?>
<td width="100" align="center">荐脚啊瓷 蜡丰雀盔荐
</td>
<td width="100" align="left"><?echo $result[0]?>
</td>
</tr>
</table>
<table width="800" border="1" cellspacing="0" cellpadding="0">
<tr bgcolor="#FFCCCC" bordercolor="#33CCCC">
<td width="60">
<div align="center">备盒</div>
</td>
<td width="60">
<div align="center">捞抚</div>
</td>
<td width="92">
<div align="center">酒捞叼</div>
</td>
<td width="97">
<div align="center">荐脚惑怕</div>
</td>
<td width="150">
<div align="center">林刮锅龋</div>
</td>
<td width="134">
<div align="center">荐脚锅龋</div>
</td>
<td width="112">
<div align="center">POINT</div>
</td>
<td width="79">
<div align="center">涝陛犬牢</div>
</td>
</tr>
<?
if($seperate==1){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user ";
$sql_cnt = "select count(*) from sms_user ";
}
else if($seperate==2){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where active_flag=1 and smspoint !=0 ";
$sql_cnt = "select count(*) from sms_user where active_flag=1 and smspoint !=0";
}
else if($seperate==3){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where grade !=1 ";
$sql_cnt = "select count(*) from sms_user where grade != 1";
}
else if($seperate==4){
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where active_flag!=1 ";
$sql_cnt = "select count(*) from sms_user where active_flag!=1 ";
}
else {
$sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user where smspoint<=0 ";
$sql_cnt = "select count(*) from sms_user where smspoint<=0 ";
}
// $sql = "select grade,username,userid,active_flag,sid,handphone,smspoint from sms_user ";
// $sql_cnt = "select count(*) from sms_user ";
if(strlen($string)){
if($seperate==1){
if($search==1){
$sql.=" where username like '%$string%' order by username";
$sql_cnt.=" where username like '%$string%'";
}
else if($search==2){
$sql.=" where handphone like '%$string%'";
$sql_cnt.=" where handphone like '%$string%'";
}
else {
$sql.=" where userid like '%$string%' order by userid";
$sql_cnt.=" where userid like '%$string%' ";
}
}
else{
if($search==1){
$sql.=" and username like '%$string%' order by username";
$sql_cnt.=" and username like '%$string%'";
}
else if($search==2){
$sql.=" and handphone like '%$string%'";
$sql_cnt.=" and handphone like '%$string%'";
}
else {
$sql.=" and userid like '%$string%' order by userid";
$sql_cnt.=" and userid like '%$string%' ";
}
}
}
else {
$sql.=" order by username";
$sql_cnt.=" order by username";
}
$result=FetchOnerecord($sql_cnt);
$total=$result[0];
Query($sql);
for($i=0;$i<$page*10;$i++)$result=Fetchrecord();
for($i=0;$i<10&&$result=Fetchrecord();$i++){
?>
<tr bgcolor="#FFFFFF" bordercolor="#33CCCC">
<td width="60">
<div align="center"><?if($result[0]==1)echo "沥雀盔";else echo "霖雀盔";?></div>
</td>
<td width="60">
<div align="center"><?if($result[1])echo $result[1];else echo " ";?></div>
</td>
<td width="92">
<div align="center"><?if($result[2])echo $result[2];else echo " "?></div>
</td>
<td width="97">
<div align="center"><?if($result[3]==1)echo "true";else echo "<font color=red>false</font>";?></div>
</td>
<td width="150">
<div align="center"><?if($result[4])echo substr($result[4],0,6)."-".substr($result[4],6,7);else echo " "?></div>
</td>
<td width="134">
<div align="center"><a href="user_view.php?page=<?echo $page?>&search=<?echo $search?>&string=<?echo $string?>&handphone=<?echo $result[5]?>"><?if($result[5])echo $result[5];else echo " "?></a></div>
</td>
<td width="112">
<div align="center"><?if($result[6])echo $result[6];else echo "0";?></div>
</td>
<td width="79">
<div align="center"><a href="./money_list.php?page=<?echo $page?>&search=<?echo $search?>&string=<?echo $string?>&handphone=<?echo $result[5]?>">涝陛犬牢</a></div>
</td>
</tr>
<?
}
?>
</table><br>
<?
//府胶飘狼 其捞瘤锅龋甫 免仿茄促.
//$pcount : 傈眉 饭内靛狼 荐
//$ppage : 免仿且 其捞瘤锅龋
//$row : 茄其捞瘤俊 免仿登绰 饭内靛荐
//$purl : 汗蓖且 林家 ,颇扼固磐 器窃 抗)$purl="kyungjuma1.php?string=$string&mapil=$mapil"
//汗蓖且版快 page颇扼固磐啊 歹 嘿绢辑 泅力 其捞瘤锅龋啊 傈崔等促.
PageList($total,$page,10,"user_list.php?string=$string&search=$search&seperate=$seperate");
?>
<form method="post" action="user_list.php">
<table width="800" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100" align="right"></td>
<td width="30" align="right"><a href="smsadmin.php">Menu</a></td>
<td width="167" align="right">
<select name="seperate">
<option value="1" <?if($seperate==1)echo "selected"?>>傈眉 雀盔</option>
<option value="2" <?if($seperate==2)echo "selected"?>>蜡丰 雀盔</option>
<option value="3" <?if($seperate==3)echo "selected"?>>OFFLINE 雀盔</option>
<option value="4" <?if($seperate==4)echo "selected"?>>荐脚焊幅 雀盔</option>
<option value="5" <?if($seperate==5)echo "selected"?>>器牢飘 绝绰 雀盔</option>
</select>
</td>
<td width="99" align="center">
<select name="search">
<option value="1" <?if($search==1)echo "selected"?>>捞抚</option>
<option value="2" <?if($search==2)echo "selected"?>>荐脚锅龋</option>
<option value="3" <?if($search==3)echo "selected"?>>ID</option>
</select>
</td>
<td width="169">
<input type="text" name="string" size="20" maxlength="20">
</td>
<td width="225">
<input type="submit" value="八祸">
</td>
</tr>
</table>
</form>
<p> </p></div>
</body>
</html>
<?
DBclose();
?>
参考资料
作者: fangzhouy 发布时间: 2010-10-03
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28