<!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=utf-8" />
<title>在线商城后台管理</title>
<link rel="stylesheet" type="text/css" href="view/admin/style/basic.css" />
<script type="text/javascript" src="view/admin/js/basic.js"></script>
{literal}
<script type="text/javascript">
function addimgsider() {
	var fm = document.contentjs;
	
	if (fm.title.value == '') {
		alert('轮播图片名称不得为空！');
		fm.title.focus();
		return false;
	}
	if (fm.title.value.length < 2) {
		alert('轮播图片名称不得小于2位！');
		fm.title.focus();
		return false;
	}
	if (fm.title.value.length > 50) {
		alert('轮播图片名称不得大于50位！');
		fm.title.focus();
		return false;
	}
	if (fm.url.value == '') {
		alert('链接地址不得为空！');
		fm.url.focus();
		return false;
	}
	if (fm.site_logo.value == '') {
		alert('请选择要上传的图片！');
		fm.site_logo.focus();
		return false;
	}
	return true;
}
</script>
{/literal}
</head>
<body>

<h2><a href="?a=imgsider">返回列表</a>界面管理 -- 添加首页轮换图片</h2>
<form method="post" name="contentjs" action="?a=imgsider&m=add">	
	<input type="hidden" value="1" name="state" />	
	<div class="add_update">		
		<table cellspacing="0">			
			<tr>
				<td class="text_right">轮播名称：</td>
				<td class="text_left">
					<input type="text" class="text" name="title" /> <span>提示：用于轮播图片下面的标题</span>
				</td>
			</tr>
			<tr>
				<td class="text_right">链接地址：</td>
				<td class="text_left">
					<input type="text" class="text" name="url" /> <span>提示：请填写正确的链接地址</span>
				</td>
			</tr>
			<tr>
				<td class="text_right">排　　序：</td>
				<td class="text_left">
					<input type="text" class="text" name="sort" value="10"/>
				</td>
			</tr>
			<tr>
				<td class="text_right">轮播图片：</td>
				<td class="text_left">
				
					<input type="hidden" name="sourcepath" class="text"/> 
					<input type="text" class="input-text" name="site_logo" class="text" readonly="readonly" value="" size=40 /> 
					<input type="button" value="上传缩略图" onclick="centerWindow('?a=upload&m=upfile&width=600&height=300','upfile','400','160')" />
					</br><img name="pic" src="" style="dispaly:none;"/> <span style="color:red;">（*不能为空，必须是jpg,gif,png，并且200k内）   提示：为了达到最佳效果，请根据模板不同，上传不同大小的图片，默认模板幻灯图宽度为700px,高度为300px</span>					
				</td>
			</tr>			
			<tr>
				<td></td>
				<td><input type="submit" name="send" onclick="return addimgsider();" value="新增首页轮换图片" class="submit level" /></td>
			</tr>
		</table>
	</div>
	
</form>


</body>
</html>