<html>
<head>
<title>角色属性设定</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<link href="/templets/default/diary/css.css" rel="stylesheet" type="text/css">
<script src="/templets/default/diary/img/alt.js"></script>
<style>
#safequestion{width:125px;}
#newsafequestion{width:125px;}
</style>
<script type="text/javascript">  
  function checkSubmit()
{
	if(document.regform.oldpwd.value=='')
	{
		document.regform.oldpwd.focus();
		alert("旧密码必须填写！");
		return false;
	}
	if(document.regform.userpwdok.value!=document.regform.userpwd.value)
	{
		document.regform.userpwdok.focus();
		alert("两次密码不一致！");
		return false;
	}
	if(document.regform.email.value=="")
	{
		document.regform.email.focus();
		alert("Email不能为空！");
		return false;
	}
	if(document.regform.uname.value=="")
	{
		document.regform.uname.focus();
		alert("用户昵称不能为空！");
		return false;
	}
	if(document.regform.vdcode.value=="")
	{
		document.regform.vdcode.focus();
		alert("验证码不能为空！");
		return false;
	}
}
</script>
<script language="javascript">
	function SwitchCover(nCover,nBookID,sImageType,sexx)
	{
	var sex=sexx
	if (sex=="女")
	     sex="g"
		else
	  sex="b"
	 	if(nCover==-1)
			preview.src="/templets/default/diary/face/"+nBookID+"."+sImageType
		else
			preview.src="/templets/default/diary/face/"+sex+nCover+""
	}
	function UploadCover(sPath)
	{
		preview.src=sPath
	}
	function SetCurrentCover(nCover)
	{
		bookcover=document.all("bookcover")
		for(var i=0;i<bookcover.options.length;i++)
		{
			if(bookcover(i).value==nCover)
			{
				bookcover(i).selected=true;
				return;
			}
		}
	}
	
</script>
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0" marginwidth="0" style="background-color=transparent">
<table width="284" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td height="370" width="284" align="right">
      <table border="0" width="284" id="table8" cellspacing="0" cellpadding="0" height="370">
          <tr> 
          <td height="19"  colspan="3" align=center><font color="#51300C">
            人物属性设置</font></td>
        </tr>
        <tr> 
          <td background="diary/linebg2.gif" colspan="3" height="1"><img border="0" src="diary/linebg2.gif" width="4" height="1"></td>
        </tr>
        <tr valign="top"> 
          <td width="284" colspan="3"> 
<form action="edit_baseinfo.php" method="post" enctype="multipart/form-data" name="regform" onsubmit="return checkSubmit();">
              
<table border="0" width="100%" id="table7" cellspacing="0" cellpadding="0" height="100%" align="center">
  <tr>
    <td></td>
    <td></td>
    <td></td>
    <td></td>
  </tr>
  <tr>
    <td width="10" height="19">&nbsp;</td>
    <td width="70" height="19"><b><font color="#77520A">注册账户:</font></b></td>
    <td width="130" height="19"> 
      <?php echo $cfg_ml->M_LoginID; ?>
      <input type="hidden" name="dopost" value="save" />
    </td>
    <td rowspan="7"><img id="preview" src="<?php echo $row['face']; ?>" width="75" height="150" style="border:1px dashed gray"></td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><b><font color="#77520A">用户笔名:</font></b></td>
    <td height="19"> 
      <input name="uname" type="text" id="uname" value="<?php echo $row['uname']; ?>" style="width:100px" readonly/>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><b><font color="#77520A">用户性别:</font></b></td>
    <td height="19"> 
      <select name="sex" class="input" id="sex" style="width:60px">
        <option value="女" <?php if($row['sex']=='女') echo " selected "; ?>>女孩</option>
        <option value="男" <?php if($row['sex']=='男') echo " selected "; ?>>男孩</option>
      </select>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>原 密 码:</b></font></td>
    <td height="19"> 
      <input name="oldpwd" type="password" id="oldpwd" style="width:100px"/><a href="#" title="【修改资料须填写原密码】" onclick="alert('【修改资料须填写原密码】');"><font color="#FF0000">*注意</font></a></td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>新 密 码:</b></font></td>
    <td height="19"> 
      <input name="userpwd" type="password" id="userpwd" />
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>重输密码:</b></font></td>
    <td height="19"> 
      <input name="userpwdok" type="password" id="userpwdok" value="" />
    </td>
  </tr>
  <tr>
    <td height="23">&nbsp;</td>
    <td height="23"><b><font color="#77520A">个人形象:</font></b></td>
    <td height="23"> 
      <select name="face" class="input" id="face" style="width:70px" onChange="SwitchCover(this.value,6913,'gif',document.regform.sex.options[document.regform.sex.selectedIndex].value)">
        <option value="01.gif" <?php if(substr($row['face'],-6)=='01.gif'||$row['face']==''||substr($row['face'],-6)=='oy.png') echo " selected "; ?>>图 
        片 1</option>
        <option value="02.gif" <?php if(substr($row['face'],-6)=='02.gif') echo " selected "; ?>>图 
        片 2</option>
        <option value="03.gif" <?php if(substr($row['face'],-6)=='03.gif') echo " selected "; ?>>图 
        片 3</option>
        <option value="04.gif" <?php if(substr($row['face'],-6)=='04.gif') echo " selected "; ?>>图 
        片 4</option>
        <option value="05.gif" <?php if(substr($row['face'],-6)=='05.gif') echo " selected "; ?>>图 
        片 5</option>
        <option value="06.gif" <?php if(substr($row['face'],-6)=='06.gif') echo " selected "; ?>>图 
        片 6</option>
        <option value="07.gif" <?php if(substr($row['face'],-6)=='07.gif') echo " selected "; ?>>图 
        片 7</option>
        <option value="08.gif" <?php if(substr($row['face'],-6)=='08.gif') echo " selected "; ?>>图 
        片 8</option>
        <option value="09.gif" <?php if(substr($row['face'],-6)=='09.gif') echo " selected "; ?>>图 
        片 9</option>
        <option value="10.gif" <?php if(substr($row['face'],-6)=='10.gif') echo " selected "; ?>>图 
        片 10</option>
      </select> <a href="/member/edit_face.php" target="_self">上传头像</a>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>电子邮箱:</b></font> </td>
    <td height="19" colspan="2"> 
      <input name="email" type="text" id="email" style="width:130px" value="<?php echo $row['email']; ?>" class="intxt"/><a href="#" title="【每个电子邮邮箱只能注册一个帐号，要修改电子邮箱必须填写正确安全问题的答案】" onclick="alert('【每个电子邮邮箱只能注册一个帐号，要修改电子邮箱必须填写正确安全问题的答案】');"><font color="#FF0000">*注意</font></a>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>原安全问题:</b></font></td>
    <td colspan="2" height="19"> 
      <?php
      			require(DEDEDATA.'/safequestions.php');
      			echo GetSafequestion($row['safequestion'],'safequestion');
     		 ?>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>原问题答案:</b></font> </td>
    <td colspan="2" height="19"> 
      <input name="safeanswer" type="text" id="safeanswer" value="" class="intxt" />
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>新安全问题</b></font>: </td>
    <td colspan="2" height="19"> 
      <?php
      			echo GetSafequestion(0,'newsafequestion');
      		?>
    </td>
  </tr>
  <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>新问题答案:</b></font></td>
    <td colspan="2" height="19"> 
      <input name="newsafeanswer" type="text" id="newsafeanswer" class="intxt"/>
    </td>
  </tr>
  <tr>
    <td height="19" align=center>&nbsp;</td>
    <td height="19"><font color="#77520A"><b>个性说明:</b></font></td>
    <td colspan="2" height="19" align=left> 
      <textarea name="lovemsg" id="lovemsg" style="width:190px;height:40px;"><?php echo $row1['lovemsg']; ?></textarea>
    </td>
  </tr>
   <tr>
    <td height="19">&nbsp;</td>
    <td height="19"><font color="#77520A"><b>验 证 码:</b></font> </td>
    <td height="19" colspan="2"> 
      <input name="vdcode" type="text" id="vdcode" style='width:50px;text-transform:uppercase;' class="intxt" />
      <img src="../include/vdimgck.php" align="absmiddle" alt="看不清？点击更换" style="cursor:pointer" onclick="this.src=this.src+'?'" /> 
    </td>
  </tr>
  <tr> 
    <td colspan="4"> </td>
  </tr>
  <tr> 
    <td colspan="4"> 
      <p align="center"> 
        <input type="submit" name="Submit" value=" 提 交 ">
        <input type="reset" name="Submit2" value=" 重 置 ">
      </p>
    </td>
  </tr>
  <tr> 
    <td colspan="4" height="100%">&nbsp;</td>
  </tr>
</table>


            </form>
          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>
</body>
</html>