<!--#include file="_header.html" -->
<script id="clientEventHandlersJS" language="javascript">
<!--

function save_onclick() {	
	if(document.Form1.elements[0].value == "")
	{
		alert("相册标题不能为空！");
		return false;
	}
	if(document.Form1.AlbumType.selectedIndex < 0)
	{
		alert("请选择相册分类！");
		return false;
	} 
	
	if(document.Form1.AlbumText.value.length > 200)
	{
		alert("相册描述长度最大为200字！"); 
		return false;
	}
	
	if(document.Form1.privatepwd.checked && document.Form1.AlbumPwd.value == "")
	{
		alert("选择保密相册必须拥有一个授权访问密码！");
		return false;
	}	
	return true;
}
//-->
</script>
<div class="mainbox">
	<div class="notice">
		<span> <!--#include file="_nav.html"--></span>&nbsp;
	</div>
	<div class="notice font14"><span>
	<a href="album_index.aspx">相册首页</a> |   
	<a href="album_list.aspx">相册分类</a> |  
	<a href="album_self.aspx">我的相册</a></span>&nbsp;
	</div>
</div>
	<table cellspacing="0" cellpadding="0" class="tablebox tableborder" ID="Table1">
	<form method="post" ID="Form1" name="Form1" action="">
		<tr>
			<th colspan="2" id="list_title">相册编辑</th>
		</tr>
		<tr>
		</tr>
		<tr>
			<td width="200" width="30%" align="right" >相册标题：</td>
			<td>
				<INPUT id="AlbumTitle" type="text" onFocus="IEvent('focus',this);"	onBlur="IEvent('blur',this);" onMouseOver="IEvent('mouseover',this)" onMouseOut="IEvent('mouseout',this)" maxLength="50" size="56" name="AlbumTitle" value="<%=Album.albumtitle%>">
				<span class="fon1">*</span>
			</td>
		</tr>
		<tr>
			<td align="right" >相册分类：</td>
			<td>
				<SELECT id="AlbumType" name="AlbumType">
					<!--{for(int i=0; i < AlbumTypeLen; i++)}-->
					<option value="<%=((Dvbbs.bbs.UI.Forum.ALBUM_TYPE)AlbumTypeArr[i]).albumtype%>"><%=((Dvbbs.bbs.UI.Forum.ALBUM_TYPE)AlbumTypeArr[i]).albumtype%></option>
					<!--{endfor}-->
				</SELECT>
				<INPUT id="AlbumSubType"  type="text" onFocus="IEvent('focus',this);"	onBlur="IEvent('blur',this);" onMouseOver="IEvent('mouseover',this)" onMouseOut="IEvent('mouseout',this)"  maxLength="50" name="AlbumSubType" size="29" value="<%=Album.albumsubtype%>"> 标签(Tags)
				<span class="fon1">*</span>
			</td>
		</tr>
		<tr>
			<td align="right" >相册描述：</td>
			<td><TEXTAREA id="AlbumText" onFocus="IEvent('focus',this);"	onBlur="IEvent('blur',this);" onMouseOver="IEvent('mouseover',this)" onMouseOut="IEvent('mouseout',this)"  name="AlbumText" rows="6" cols="43"><%=Server.HtmlEncode(Album.albumtext)%></TEXTAREA></td>
		</tr>
		<tr>
			<td align="right" >相册设置：</td>
			<td>
				<INPUT id="Radio1" type="radio" value="0" name="RadioGroupAlbumClass" class="checkbox"
					checked="true">普通相册&nbsp; <INPUT id="Radio2" type="radio" value="1" name="RadioGroupAlbumClass" class="checkbox">推荐相册&nbsp;
				<INPUT id="Radio3" type="radio" value="2" name="RadioGroupAlbumClass" class="checkbox">精华相册
				<span class="fon1">*</span>
			</td>
		</tr>
		<tr>
			<td align="right" >是否公开：</td>
			<td>
				<INPUT id="AlbumPublic" type="radio" value="1" name="RadioGroupIsHowDo" class="checkbox"
					checked="true">公开相册&nbsp; <INPUT id="AlbumPrivate" type="radio" value="0" name="RadioGroupIsHowDo" class="checkbox">私人相册&nbsp;
				<INPUT id="privatepwd" type="radio" value="2" name="RadioGroupIsHowDo" class="checkbox">保密&nbsp;
				<INPUT id="AlbumPwd" type="text" onmouseover="this.className='TextBoxFocus'" onmouseout="this.className='TextBox'" maxLength="20" size="16" name="AlbumPwd" value="<%=Album.accesspwd%>">
				<span class="fon1">*</span>
			</td>
		</tr>
		<tr>
			<td colspan="2" align="center">
				<input id="save" type="submit" name="save" onMousemove="this.className='button_on';" onMouseout="this.className='button_off'" value="确  定" onclick="return save_onclick()" class="button_off" />
		&nbsp; &nbsp;
		       <input id="return" type="button" name="return" onMousemove="this.className='button_on';" onMouseout="this.className='button_off'" value="返  回" onclick="window.location='album_self.aspx';" class="button_off" />			
			</td>
		</tr>
		<tr>
		<td colspan="2">
		  <br />
		</td>
		</tr>
	</form>
	</table>
<script type="text/javascript" language="javascript">
var albumtype = document.getElementById("AlbumType");
var l = albumtype.length;
var i=0;
for(;i<l;i++){
	if(albumtype.options[i].value=='<%=Album.albumtype%>'){
		albumtype.options[i].selected=true;break;
	}
} 

var albumclass = <%=Album.albumclass%>
if(albumclass == 0)
	document.getElementById("Radio1").checked = true;
if(albumclass == 1)
	document.getElementById("Radio2").checked = true;
if(albumclass == 2)
	document.getElementById("Radio3").checked = true;
		
var ishowdo = <%=Album.ishowdo%>;
if(ishowdo == 0)
	document.getElementById("AlbumPrivate").checked = true;
if(ishowdo == 1)
	document.getElementById("AlbumPublic").checked = true;
if(ishowdo == 2)
	document.getElementById("privatepwd").checked = true;
</script>
<!--#include file="_footer.html" -->