<!--#include file="../siteconfig/conn.asp"-->
<!--#include file="../siteconfig/md5.asp"-->
<%
if session("adminlogin")<>sessionvar then
Response.Write("<script language=javascript>alert('你尚未登录，或者超时了！请重新登录');this.location.href='login.asp';</script>")
Response.End
End if
%>
<!--#include file="Admin_ManageFunction.asp"-->
<HTML>
<HEAD>
<TITLE>添加模板分类</TITLE>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> 
<LINK REL="stylesheet" HREF="css.css" TYPE="text/css">
</HEAD>
<script language="JavaScript" type="text/javascript" src="js.js"></script>
<BODY>
<%dim Menu,SkinClass_Name,SkinClass_Memo
SkinClass_Name=Trim(Request("SkinClass_Name"))
SkinClass_Memo=Request("SkinClass_Memo")
Menu=Request("Menu")
if Menu="AddSkinClass" then
   rs.open"select * from SkinClass where SkinClass_Name='"&SkinClass_Name&"'",conn,1,3
   if not rs.eof and not rs.bof then
         Response.Write("<script language=javascript>alert('分类名称已存在!');this.location.href='?SkinClass_Id="&SkinClass_Id&"';</script>")
	     Response.End()
   end if
   rs.close
   rs.open"select * from SkinClass",conn,1,3
      rs.addnew
	  rs("SkinClass_Name")=SkinClass_Name
	  rs("SkinClass_Memo")=SkinClass_Memo
   rs.update
   rs.close
   Response.Write("<script language=javascript>alert('模板分类添加成功');parent.window.location.reload();DivOpenClose('',2,0,0);</script>")
   Response.End()
end if%>
<table width="100%" border="0" align="center" cellpadding="5" cellspacing="1" bgcolor="#EEEEEE">
  <tr>
    <td width="45%">添加模板分类</td>
    <td width="55%" align="right"><a href="#" onClick="javascript:DivOpenClose('',2,0,0);return false">关闭</a></td>
  </tr>
</table>
<form name="SkinClassFrom" method="post" action="?Menu=AddSkinClass" id="SkinClassFrom" onSubmit="return SkinClassCheck();">
<table width="100%" border="0" align="center" cellpadding="5" cellspacing="1" bgcolor="#EEEEEE">
  <tr bgcolor="#FFFFFF">
    <td>模板分类名称</td>
    <td><input name="SkinClass_Name" type="text" class="inputcss"
	 id="SkinClass_Name" size="20"></td>
  </tr>
  <tr bgcolor="#FFFFFF">
    <td>模板分类描术</td>
    <td><input name="SkinClass_Memo" type="text" class="inputcss" id="SkinClass_Memo" size="20"></td>
  </tr>
  <tr bgcolor="#FFFFFF">
    <td>&nbsp;</td>
    <td><input name="Submit" type="submit" class="SubmitCss" value="添加模板分类"></td>
  </tr>
</table>
</form>
</BODY>
</HTML>

