<?php
if(empty($op)) $op='zl';
?>
  <!--- content -->
  <div class="neir">
    <div class="top">个人设置</div>
      <div class="content">
		<div class="main_nav">
			<ul>
				<li class="<?php if($op=='zl'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=zl">资料设置</a></li>
				<li class="<?php if($op=='pass'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=pass">修改密码</a></li>
				<li class="<?php if($op=='logo'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=logo">头像设置</a></li>
				<li class="<?php if($op=='mb'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=mb">主页模版</a></li>
				<li class="<?php if($op=='pic'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=pic">主页背景</a></li>
				<li class="<?php if($op=='bo'){ echo 'nava_4';}else{ echo 'navb_5';}?>"><a href="?ac=edit&op=bo">背景音乐</a></li>
			</ul>
		</div>
<?php if($op=='logo'){ ?>
	             <table class="user_mod_list" cellpadding="0" cellspacing="0">
		             <tr><td height='50'><span class="t"><i>*</i>本地上传：</span><span class="button-main"><span><button type="button" onclick="Popsboxif('上传头像',470,100,'uplogo.php');" id="ziliao" >上传头像</button></span></span></td></tr>
		             <tr><td height='70'><span class="t"><i>*</i>小头像：</span><img id="img2" src="<?php echo $cscms_logo?>" width=48 height=48 style="border:1px solid #ccc;" /></td></tr>
		             <tr><td height='200'><span class="t"><i>*</i>大头像：</span><img id="img1" src="<?php echo $cscms_logo?>" width=125 height=125 style="border:1px solid #ccc;"></td></tr>
		    </table>
<?php }elseif($op=='zl'){ ?>
		   <div class="main_nav2">
<script type="text/javascript" charset="utf-8" src="../public/editor/kindeditor.js"></script>
<script type="text/javascript">
     KE.show({
	id : 'content',
	resizeMode : 1,
	allowPreviewEmoticons : false,
	allowUpload : false,
	items : [
	'source', '|', 'fontsize', 'textcolor', 'bgcolor', 'bold', 'italic', 'underline',
	'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
	'insertunorderedlist', '|', 'image', 'link', 'unlink']
     });
</script>
<script src="js/city.js"></script>
<script language="javascript">
$(document).ready(function(){
	$("#ziliao").click(function(){
		var CS_Nichen=$("#CS_Nichen").val();
		var CS_City=$("#CS_City").val();
		var CS_QQ=$("#CS_QQ").val();
	$("#CS_Nichen").css("border-color","#666 #ccc #ccc #666");
	$("#CS_City").css("border-color","#666 #ccc #ccc #666");
	$("#CS_QQ").css("border-color","#666 #ccc #ccc #666");
	if(CS_Nichen==""){
		$("#Msg").text("出错了，请填写您的昵称！").css("color","red");
		return false;
		}
	else if(CS_City==""){
		$("#CS_City").css("border","1px solid red");
		$("#Msg").text("出错了，请填写您的地区！").css("color","red");
		return false;
		}
	else if(CS_QQ==""){
		$("#CS_QQ").css("border","1px solid red");
		$("#Msg").text("出错了，请填写您的QQ！").css("color","red");
		return false;
		}
	});
});
</script>
	             <form action="do.php?ac=edit&op=zl" method="post">
	             <table class="user_mod_list" cellpadding="0" cellspacing="0">
		             <tr><td height='50'><span class="t"><i>*</i>用户名：</span><input type="text" class="input_only" id="CS_Name" name="CS_Name" value="<?php echo $cscms_name?>" readonly="true"><span class="reg_msg">不能修改</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>邮箱：</span><input type="text" class="input_only" id="CS_Email" name="CS_Email" value="<?php echo $cscms_email?>"><span class="reg_msg">修改请联系管理员。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>昵称：</span><input type="text" class="user_reg_input" id="CS_Nichen" name="CS_Nichen" value="<?php echo $cscms_nichen?>"><span class="reg_msg" id="username_info">不能使用空格、数字、和 &lt; &gt; ' " / \ 等非法字符。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>性别：</span><span class="select"><select name="CS_Sex" id="CS_Sex"><option value="0" <?php if($cscms_sex==0) echo 'selected="selected"';?>>帅哥</option><option value="1" <?php if($cscms_sex==1) echo 'selected="selected"';?>>美女</option></select></span><span class="reg_msg">请选择您的性别。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>城市：</span><input type="hidden" class="user_reg_input" id="hid2" name="CS_City" value="<?php echo $cscms_city?>">
		             <div>
   		              <div class="ddlShouhuo ddldisplay" id="ddlSheng">
       		              <span id="txtSheng" runat="server"><?php echo $city[0]?></span>
       		              <div></div>
    		             </div>
   		             <div class="ddlShouhuo ddldisplay" id="ddlShi">
      		               <span id="txtShi" runat="server"><?php echo $city[1]?></span>
       		              <div></div>
    		             </div>
    		             <div class="ddlShouhuo ddldisplay" id="ddlQu">
       		              <span id="txtqu" runat="server"><?php echo $city[2]?></span>
       		              <div></div>
    		             </div>
    		             </div>
		             <span class="reg_msg">请选择您的城市。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>QQ：</span><input type="text" class="user_reg_input" id="CS_QQ" name="CS_QQ" value="<?php echo $cscms_qq?>"><span class="reg_msg">输入您的QQ号，只供站务人员联系使用，不会公开。</span></td></tr>
		             <tr><td style="height:130px;"><span class="t"><i>*</i>签名：</span><textarea style="width:435px;height:120px;" id="content" name="CS_Qianm"><?php echo $cscms_qianm?></textarea></td></tr>
	             </table><div id="Msg"></div>
	             <div style="padding-top:10px;margin-left:150px;"><span class="button-main"><span><button type="submit" id="ziliao" >确定修改</button></span></span></div>
	             </form>
		   </div>
<?php }elseif($op=='pass'){ ?>
		   <div class="main_nav2">
<script language="javascript">
$(document).ready(function(){
	$("#passedit").click(function(){
		var CS_Pass=$("#CS_Pass").val();
		var CS_Pass1=$("#CS_Pass1").val();
		var CS_Pass2=$("#CS_Pass2").val();
	$("#CS_Pass").css("border-color","#666 #ccc #ccc #666");
	$("#CS_Pass1").css("border-color","#666 #ccc #ccc #666");
	$("#CS_Pass2").css("border-color","#666 #ccc #ccc #666");
	if(CS_Pass==""){
		$("#CS_Pass").css("border","1px solid red");
		$("#Msg").text("出错了，请填写您的原密码！").css("color","red");
		return false;
		}
	else if(CS_Pass1==""){
		$("#CS_Pass1").css("border","1px solid red");
		$("#Msg").text("出错了，请填写您的新密码！").css("color","red");
		return false;
		}
	else if(CS_Pass1!=CS_Pass2){
		$("#CS_Pass2").css("border","1px solid red");
		$("#Msg").text("出错了，两次新密码不一直！").css("color","red");
		return false;
		}
	});
});
</script>
	             <form action="do.php?ac=edit&op=pass" method="post">
	             <table class="user_mod_list" cellpadding="0" cellspacing="0">
		             <tr><td height='50'><span class="t"><i>*</i>原密码：</span><input type="password" class="user_reg_input" id="CS_Pass" name="CS_Pass" value=""><span class="reg_msg">您的原密码。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>新密码：</span><input type="password" class="user_reg_input" id="CS_Pass1" name="CS_Pass1" value=""><span class="reg_msg">输入您的新密码。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>密码确定：</span><input type="password" class="user_reg_input" id="CS_Pass2" name="CS_Pass2" value=""><span class="reg_msg">确定新密码。</span></td></tr>
		    </table><div id="Msg"></div>
	             <div style="padding-top:10px;margin-left:150px;"><span class="button-main"><span><button type="submit" id="passedit" >确定修改</button></span></span></div>
	             </form>
		</div>
<?php }elseif($op=='mb'){ ?>
		   <div class="main_nav2">
		      <div class="mb">
               <?php
                      for($j=0;$j<10;$j++){
                        $mm="0".($j+1)."";
                        if($mm=='010') $mm='10';
               ?>
     			<dl>
				<dt><div><a href="<?php echo $cscms_link?>&mbid=<?php echo $mm?>" target='_blank'><img src="images/mb/<?php echo $mm?>.gif" width="80" height="80" title="浏览效果" /></a></div>
				<span><a href="<?php echo $cscms_link?>&mbid=<?php echo $mm?>" target='_blank'><b><?php echo $cscms_mb[$j]?></b></a></span>
				<span><?php $mbid=$mm; if($cscms_mbid==$mbid){ ?>正使用该模板<?php }else{ ?><a href="<?php echo $cscms_link?>&mbid=<?php echo $mm?>" target='_blank'>浏览</a>&nbsp; | &nbsp;<a href="javascript:void(0);" onClick="usermb('<?php echo $mbid?>')">启用</a><?php } ?></span>
				</dt>
			</dl>
                <?php } ?>
    		     </div>
		   </div>
<?php }elseif($op=='bo'){ ?>
<script language="javascript">
$(document).ready(function(){
	$("#playadd").click(function(){
		var CS_Bname=$("#CS_Bname").val();
		var CS_Btop=$("#CS_Btop").val();
		var CS_Bleft=$("#CS_Bleft").val();
	$("#CS_Burl").css("border-color","#666 #ccc #ccc #666");
	$("#CS_Btop").css("border-color","#666 #ccc #ccc #666");
	$("#CS_Bleft").css("border-color","#666 #ccc #ccc #666");
	if(CS_Bname==""){
		$("#CS_Bname").css("border","1px solid red");
		$("#Msg").text("出错了，请填写歌曲名称！").css("color","red");
		return false;
		}
	else if(CS_Btop==""){
		$("#CS_Btop").css("border","1px solid red");
		$("#Msg").text("出错了，请填写播放器距顶高度！").css("color","red");
		return false;
		}
	else if(CS_Bleft==""){
		$("#CS_Bleft").css("border","1px solid red");
		$("#Msg").text("出错了，请填写播放器距左宽度！").css("color","red");
		return false;
		}
	});
});
</script>
	             <form action="do.php?ac=edit&op=bo" method="post">
	             <table class="user_mod_list" cellpadding="0" cellspacing="0">
		             <tr><td height='50'><span class="t"><i>*</i>歌曲名称：</span><input type="text" class="user_reg_input" id="CS_Bname" name="CS_Bname" value="<?php echo $cscms_bname?>"><span class="reg_msg"><font color=red>主页背景音乐，填上您在本站上传分享的歌曲名称！</font></span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>距顶：</span><input type="text" class="user_50_input" id="CS_Btop" name="CS_Btop" value="<?php echo $cscms_btop?>" onkeyup="this.value=this.value.replace(/[^\d]/g,'')" onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d]/g,''))"><span class="reg_msg">主页播放器离顶部多少PX。</span></td></tr>
		             <tr><td height='50'><span class="t"><i>*</i>距左：</span><input type="text" class="user_50_input" id="CS_Bleft" name="CS_Bleft" value="<?php echo $cscms_bleft?>" onkeyup="this.value=this.value.replace(/[^\d]/g,'')" onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d]/g,''))"><span class="reg_msg">主页播放器离左边多少PX。</span></td></tr>
		    </table><div id="Msg"></div>
	             <div style="padding-top:10px;margin-left:150px;"><span class="button-main"><span><button type="submit" id="playadd" >确定修改</button></span></span></div>
	             </form>
	             <div style="padding-top:10px;margin-left:150px;"><EMBED pluginspage=http://www.macromedia.com/go/getflashplayer src=../home/images/play.swf?mp3=<?php echo $cscms_bmp3?>&autoStart=yes&repeatPlay=yes&name=<?php echo $cscms_bname?>&.swf width=210 height=110 type=application/x-shockwave-flash wmode="transparent" quality="high"></EMBED></div>

<?php }elseif($op=='pic'){ ?>
		   <div class="main_nav2">
	            <table class="user_mod_list" cellpadding="0" cellspacing="0">
		             <tr><td><span class="t"><i>*</i>主页背景：</span><span class="button-main"><span><button type="button" onclick="Popsboxif('上传主页背景',470,100,'uppic.php?ac=bg');">上传背景</button></span></span><span class="reg_msg" id="sid_info">建议背景图片限定1MB，jpg或gif格式。建议像素大小为1008px*650px以上。</span></td></tr>
		             <tr><td style="height:250px;"><span class="t">浏览：</span><img src="<?php echo $cscms_bgpic?>" width="240" height="200"/></td></tr>
		             <tr><td><span class="t"><i>*</i>标题图片：</span><span class="button-main"><span><button type="button" onclick="Popsboxif('上传主页标题图片',470,100,'uppic.php?ac=top');">上传标题</button></span></span><span class="reg_msg" id="sid_info">建议标题图片限定500KB，jpg或gif格式。建议像素大小为960px*100px。</span></td></tr>
		             <tr><td style="height:120px;"><span class="t">浏览：</span><img src="<?php echo $cscms_toppic?>" width="445"/></td></tr>
		    </table>
    		   </div>
<?php } ?>
      </div>
    <div class="end"></div>
  </div>