www.gusucode.com > 仿51.com的php源码 1.1 > Image/ImageBg.php

    <?php
include("../User/CheckLogined.php");
include("../include/dbclass.php");
$dbc=new DbConn();
$uid=$_COOKIE["uid"];
$sql="select Imagebg from userdata where User_Account='$uid'";
$row=$dbc->getRs($sql);
$bg=$row["Imagebg"];
//exit();
if($_GET["action"]=="save")
{
$bg_radio=$_POST["bg_radio"];
$SQL="update userdata set Imagebg='$bg_radio' where User_Account='$uid'";
$dbc->Execute($SQL);
echo "<script>alert('保存成功!');location.href='ImageBg.php';</script>";

}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>村委会档案管理中心 --图库</title>
<link href="../images/User_Main.css" rel="stylesheet" type="text/css" />
<script>
try{
	if(top!=window){
		document.domain	="www.wu-liao.com";		
	}else{
		top.location.href="/webin.php?refer=%2FImage%2FImageBg.php";
	}
}catch(e){}
function showNewMessage(user){
	top.showNewMessage(user);
}

</script>
</head>
<body>
<div id="top">
<div id="logo"><a href="/User/Main.php"></a></div>
<div id="topr">
<div id="exit"><?php require("../menu.php"); ?>
<div id="menu">
<div class="m2">
<div class="mg"><a href="/User/Main.php">用户管理中心</a></div>
<div class="mh"><a href="/Diary/DiaryList.php">日记文集</a></div>
<div class="ma"><a href="/Photo/PhotoList.php">相册</a></div>
<div class="ma" id="do4"><a href="ImageList.php">图库</a></div>
<div class="mb"><a href="/Music/MusicList.php">音乐</a></div>
<div class="mc"><div id="ms"><a href="/Memo/MemoList.php"><img src="../images/suo2.gif" width="10" height="12" />&nbsp;秘密记事本</a></div>
</div>
<div class="me"><a href="/Fav/FavList.php">网址收藏夹</a></div>
<div class="mf"><a href="/Addr/AddrList.php">通讯录</a></div>
</div>
</div>
</div>
<div id="nav">
<div id="navt">如果您发现网上有好看的图片,请不要记了收藏哟</div>
</div>

<div id="mjx"></div>
<div id="main">
<div id="left">
<div id="leph">
<div class="phff">
<div class="phtt">
图库分类</div>
<?php 
$sql1="select * from ImageGroup where User_Account='$uid' order by GroupOrder desc";
$result=$dbc->query($sql1);
while ($row=@mysql_fetch_array($result)) {

?>
<?php $Str_photo_class=$Str_photo_class.'"'.$row["GroupName"].'",';?>
<?php if ($row["GroupName"]==$group){?>
<div class="phl1"><div class="phz "><a href="ImageList.php?group=<?php echo $row["GroupName"]; ?>" title="<?php echo $row["GroupName"]; ?>"><?php echo $row["GroupName"]; ?></a></div></div><?php }else{?><div class="phl2 "><a href="ImageList.php?group=<?php echo $row["GroupName"]; ?>" title="<?php echo $row["GroupName"]; ?>"><?php echo $row["GroupName"]; ?></a></div><?php }?>

<?php }?> <div class=phl2 style='font-size:12px;color:red'><div class="phz" ><a href='/FixGroup.php' target=_blank></a></div></div></div>
<div class="mxle"><a href="ImageGroup.php">分类管理</a></div><div class="mxle"><a href="ImageCommentToMe.php">评论管理</a></div><div class="mxle" id="xzle">背景设置</div></div>
</div>
<div id="right">
<div id="fenle">
<form id="form1" name="form1" method="post" action="?action=save" enctype="multipart/form-data" >
<DIV style="height:24px;border-bottom:1px solid;border-bottom-color:#6DA8D3;text-align:left;margin-top:15px;magin-bontom:10px;font-size:14px;font-weight:bold;color:#367DC6;">普通会员</DIV>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/001.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/002.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/003.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/004.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/005.gif" width="100" height="100" class="photo" /></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio" value="/i/userbg/001.gif" />		选择</td>
<td><input type="radio" name="bg_radio" value="/i/userbg/002.gif" />		选择</td>
<td><input type="radio" name="bg_radio" value="/i/userbg/003.gif" />		选择</td>
<td><input type="radio" name="bg_radio" value="/i/userbg/004.gif" />		选择</td>
<td><input type="radio" name="bg_radio" value="/i/userbg/005.gif" />		选择</td>
</tr>
</table>
<DIV style="height:24px;border-bottom:1px solid;border-bottom-color:#6DA8D3;text-align:left;margin-top:15px;magin-bontom:10px;font-size:14px;font-weight:bold;color:#367DC6;">只有VIP会员才能使用下面的</DIV>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/006.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/007.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/008.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/009.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/010.gif" width="100" height="100" class="photo" /></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio"   disabled value="/i/userbg/006.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/007.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/008.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/009.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/010.gif" />		选择</td>
</tr>
</table>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/011.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/012.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/013.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/014.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/015.gif" width="100" height="100" class="photo" /></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio"   disabled value="/i/userbg/011.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/012.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/013.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/014.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   disabled value="/i/userbg/015.gif" />		选择</td>
</tr>
</table>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/016.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/017.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/018.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/019.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/020.gif" width="100" height="100" class="photo" /></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/016.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/017.gif" />		选择</td>
<td><input type="radio" name="bg_radio"   <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/018.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/019.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/020.gif" />		选择</td>
</tr>
</table>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/021.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/022.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/023.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/024.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/025.gif" width="100" height="100" class="photo" /></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/021.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/022.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/023.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/024.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/025.gif" />		选择</td>
</tr>
</table>
<table height="157" border="0" cellpadding="0" cellspacing="1" width="570px">
<tr>
<td height="125">
<img src="/i/userbg/026.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/027.gif" width="100" height="100" class="photo" /></td>
<td><img src="/i/userbg/028.gif" width="100" height="100" class="photo" /></td>
<td></td>
<td></td>
</tr>
<tr>
<td height="31">
<input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/026.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/027.gif" />		选择</td>
<td><input type="radio" name="bg_radio"  <?php if($_COOKIE["vip"]==0){?> disabled<?php }?> value="/i/userbg/028.gif" />		选择</td>
<td></td>
<td></td>
</tr>
</table>

<script language="JavaScript">
<!--
var obj = document.all.bg_radio;
len = obj.length;
for(i=0;i<len;i++){
	if (obj[i].value == "<?php echo $bg; ?>"){
		obj[i].checked = true;
		break;
	}
}
//-->
</script>
<table height="60" border="0" cellpadding="0" cellspacing="1" style="text-align:left;width:570px;">
<tr>
<td height="25">
<input type=submit value="保存背景设置" class="btn">
</td>
</tr>
</table>
</form>
</div>
</div>
</div>
<div id="bottom">
<div id="baidu" style="color:#a0a0a0;"><?php require("../foot.php"); ?></div>
</div>
<?php $dbc->free_result($result);?>
</body>
</html>