<!--#include file="conn.asp"-->
<!--#include file="inc/cookies_check.asp"-->
<!--#include file="inc/Page_cls.asp"-->
<!--#include file="../include/config.inc"-->
<%
'*****************************************
'* 软件名称 乐彼网上开店软件(56770 EShop)
'* 软件开发 http://www.56770.com
'* 版权所有 http://www.56770.com
'* 文件名称 admin_common.asp
'* 最后更新 2013-03-01 by 56770.kingdge
'*****************************************
Dim admin_flag
admin_flag=",9.6,"
include "lang/"& LangFilePath &"/lang_sys.inc"
include "lang/"& LangFilePath &"/lang_menu.inc"
include "lang/"& LangFilePath &"/lang_common.inc"
CurrentId = 6
CurrentUrl = "admin_common.asp"
LB_Head()
LB_Menu()
action = request("action")
%>
<div class="tabmenu mainwidth">
	  <ul>
		<li <%If action = "" Then Response.Write("class=""current""") End If%>><a href="admin_common.asp"><span><%=Lang_Menu(193)%></span></a></li>
		<li <%If action = "type_list" Then Response.Write("class=""current""") End If%>><a href="?action=type_list"><span><%=Lang_Common(15)%></span></a></li>
		<li <%If action = "type_add" Then Response.Write("class=""current""") End If%>><a href="?action=type_add"><span><%=Lang_Common(16)%></span></a></li>
		<%If action = "type_edit" Then%><li class="current"><a href="#"><span><%=Lang_Common(3)%></span></a></li><%End If%>
		<%If action = "mes_add" Then%><li class="current"><a href="#"><span><%=Lang_Common(5)%></span></a></li><%End If%>
	  </ul>
</div>
<%
Response.Write("<div class=""tab-mainbody"">")
Response.Write("<div class=""tab-mainbody2"">")
If Eshop_Lebi_name="" Or instr(","&Eshop_Lebi_flag&",",admin_flag)=0 Then
		adminflag()
End If
Select Case action
		Case "type_add" : type_add()
		Case "type_add_ok" : type_add_ok()
		Case "type_edit" : type_edit()
		Case "type_edit_ok" : type_edit_ok()
		Case "type_del" : type_del()
		Case "type_list" : type_list()
		Case "type_update" : type_update()
		Case "mes_add" : mes_add()
		Case "mes_add_ok" : mes_add_ok()
		Case Else
			list()
End Select
Response.Write("</div>")
Response.Write("</div>")
LB_Footer()

Sub type_add_ok()
        If OnlyRead = 1 Then OnlyReadMessage()
		t_name = Safereplace(request("t_name"& lang))
		t_tag = Safereplace(request("t_tag"))
		t_order = CheckNum(request("t_order"),0)
		t_show = CheckNum(request("t_show"),0)
		sql="select * from [Lebi_Commontype] where t_tag='"&t_tag&"'"
		set rs=server.createobject("ADODB.Recordset")
		rs.open sql, conn, 1, 3
		If Not (rs.eof or rs.bof) Then
				response.write"<SCRIPT language=JavaScript>alert('"& Lang_Common(25) &"');javascript:history.go(-1)</SCRIPT>"
				response.End
		Else
				rs.addnew
				For LangT = 1 To TotalLang
						rs("t_name" & LanguageTxt(LangT))=safereplace(request("t_name" & LanguageTxt(LangT)))
				Next
				rs("t_tag") = t_tag
				rs("t_order") = t_order
				rs("t_type") = 1
				rs("t_show") = t_show
				rs.update
		End If
		rs.close:set rs=Nothing
		ManageLog Lang_Common(1) &" ["& newstype &"]"
		Call Up_mes(Lang_sys(45),"·"& Lang_sys(44),0,"?action=type_list",0,0,2,1)
End Sub

Sub type_edit_ok()
        If OnlyRead = 1 Then OnlyReadMessage()
		id = checknum(request("id"),0)
		t_name = Safereplace(request("t_name"& lang))
		t_tag = Safereplace(request("t_tag"))
		t_order = CheckNum(request("t_order"),0)
		t_show = CheckNum(request("t_show"),0)
		Set rs = conn.execute("select t_id from [Lebi_Commontype] where t_id <> "& id &" and t_tag='"&t_tag&"'")
		If Not rs.eof Then 
				response.write"<SCRIPT language=JavaScript>alert('"& Lang_Common(25) &"');javascript:history.go(-1)</SCRIPT>"
				response.End
		End If 
		rs.close : Set rs = Nothing 
		sql="select * from [Lebi_Commontype] where t_id="& id &""
		set rs=server.createobject("ADODB.Recordset")
		rs.open sql, conn, 1, 3
		If Not (rs.eof or rs.bof) Then
				If CStr(t_tag) <> CStr(rs("t_tag")) Then 
						conn.execute("update [Lebi_Common] set t_tag = '"& t_tag &"' where t_tag = '"& rs("t_tag") &"'")
				End If 
				For LangT = 1 To TotalLang
						rs("t_name" & LanguageTxt(LangT))=safereplace(request("t_name" & LanguageTxt(LangT)))
				Next
				rs("t_tag") = t_tag
				rs("t_order") = t_order
				rs("t_show") = t_show
				rs.update
		End If
		rs.close:set rs=Nothing
		ManageLog Lang_Common(4) &" ["& newstype &"]"
		Call Up_mes(Lang_sys(48),"·"& Lang_sys(47),0,"?action=type_list",0,0,2,1)
End Sub

Sub type_update()
        If OnlyRead = 1 Then OnlyReadMessage()
		t_id = Replace(Safereplace(trim(request("t_id")))," ","")
		t_order = Replace(Safereplace(trim(request("t_order")))," ","")
		t_show = Replace(Safereplace(trim(request("t_show")))," ","")
		If UBound (Split(t_id,",")) = 0 Then
                set rs=server.CreateObject("adodb.recordset")
                rs.open "select * from [Lebi_Commontype] where t_id=" & t_id, conn, 1, 3
				rs("t_order") = t_order
				rs("t_show") = t_show
                rs.update
                rs.close:set rs=Nothing
		Else
		        For edit_i = 0 To UBound (Split(t_id,","))
                        set rs=server.CreateObject("adodb.recordset")
                        rs.open "select * from [Lebi_Commontype] where t_id=" & Split(t_id,",")(edit_i), conn, 1, 3
                        rs("t_order") = Checknum(Split(t_order,",")(edit_i),0)
						rs("t_show") = Checknum(Split(t_show,",")(edit_i),0)
                        rs.update
                        rs.close:set rs=Nothing
                Next
		End If
        Call Up_mes(Lang_sys(48),"·"& Lang_sys(47),0,"?action=type_list&page="& request("page") &"",0,0,2,1)
End Sub

Sub type_del()
        If OnlyRead = 1 Then OnlyReadMessage()
        del_id= Replace(safereplace(Trim(request("id"))),"，",",")
		If Right(del_id,1) = "," Then del_id = Left(del_id,Len(del_id)-1)
        if del_id="" then
                response.write"<SCRIPT language=JavaScript>alert('"& Lang_sys(41) &"');javascript:history.go(-1)</SCRIPT>"
                response.end
        end If
		Set rs = server.CreateObject("adodb.recordset")
		rs.open "select t_tag from [Lebi_Commontype] where t_id in (" & del_id &")",conn,1,3
		Do While Not rs.eof
				conn.execute("delete from [Lebi_Common] where t_tag = '"& rs(0) &"'")
				rs.delete
				rs.update
		rs.movenext
		Loop
		rs.close : Set rs = Nothing
		ManageLog Lang_Common(2) &" ["&del_id&"]"
        Call Up_mes(Lang_sys(43),"·"& Lang_sys(42),0,"?action=type_list&page="& request("page") &"",0,0,2,1)
End Sub

Sub mes_add_ok()
		tag = safereplace(request("tag"))
		set rs=server.CreateObject("adodb.recordset")
		rs.open "select * from [Lebi_Common] where t_tag='" & tag &"'", conn, 1, 3
		If rs.eof Then
				rs.addnew()
		End If 
		For LangT = 1 To TotalLang
				If request("savepic" & LanguageTxt(LangT)) = "1" Then
						FilesPath="../pic/userfiles/image/"
						rs("c_content" & LanguageTxt(LangT))=ReplaceSaveRemoteFile(Replace(request("message" & LanguageTxt(LangT)),"'","&#180;"),False,True,True,FilesPath,Eshop_url)
				Else
						rs("c_content" & LanguageTxt(LangT))=Replace(request("message" & LanguageTxt(LangT)),"'","&#180;")
				End If
		Next
		rs("t_tag")=tag
		rs.update
		rs.close:Set rs=Nothing
		ManageLog Lang_Common(27) &" ["& tag &"]"
		Call Up_mes(Lang_sys(48),"·"& Lang_sys(47),0,"?",0,0,2,1)
End Sub 

sub list()
		Dim admin_flag
		admin_flag=",5.2,"
		if Eshop_Lebi_name="" or instr(","&Eshop_Lebi_flag&",",admin_flag)=0 then
				adminflag()
		End If
		classid = CheckNum(request("classid"),0)
		ntype = CheckNum(request("ntype"),0)
		page = CheckNum(request("page"),1)
		datefrom=safeReplace(request("datefrom"))
		dateto=safeReplace(request("dateto"))
		state=safeReplace(request("state"))
		keyword=safeReplace(request("keyword"))
		lang = safereplace(request("lang"))
		If lang = "" Then lang = LanguageTxt(0)
		Dim ors
		Set ors=new Cls_vbsPage
		Set ors.Conn=conn
		With ors
		.PageSize=15
		.PageName="Page"
		If IsSqlDataBase = 0 Then
				.DbType="AC"
		Else
				.DbType="MSSQL"
		End If
		.RecType=-1
		.Pkey="t_id"
		.Field="t_id,t_name"& lang &",t_tag"
		.Table="[Lebi_Commontype]"
		sql = "t_type=1"
		If keyword <> "" Then sql = sql &" and t_name"& lang &" like '%"& keyword &"%'"
		.Condition=sql
		.OrderBy="t_order desc"
		End With
		DataCount=ors.RecCount()
		DataList=ors.ResultSet()
%>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="classtable-top">
<tbody>
<tr>
<form name="form" action="?" method="get">
<td height="30" align="left" class="classhead">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<select name="lang">
<option value="0" selected>┌ <%=Lang_sys(67)%></option>
<%For LangT = 1 To TotalLang%>
<option value="<%= LanguageTxt(LangT) %>"<%=judge2(LanguageTxt(LangT),Lang)%>>├ <%= LanguageName(LangT) %></option>
<%Next%>
</select>
</td>
<td style="padding-left:5px;">
<input type="text" name="keyword" value="<%= keyword %>" class="form_query" size="15"><input name="Submit" type="submit" value="" title="<%=Lang_sys(25)%>" align="absmiddle" class="btn_query">
</td>
</tr>
</table>
</form>
</td>
<td height="30" align="right" colspan="2" class="classhead">
<%=QuickMenu("admin_print_tpl.asp|"& Lang_Menu(196) &"","?action=type_list|"& Lang_Common(15) &"")%>
</td>
</tr>
</form>
</tbody>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="classtable" class="classtable2">
<tbody>
<tr>
<td width="50%" height="30" class="classtop"><%=Lang_Common(14)%></td>
<td width="15%" class="classtop"><%=Lang_Common(19)%></td>
<td width="25%" class="classtop"><%=Lang_Common(33)%></td>
<td width="10%" class="classtop"><%=Lang_Common(17)%></td>
</tr>
<%
If DataCount >0 Then
		For i = 0 To Ubound(DataList,2)
%>
<tr class="classrow">
<td height="30" class="classrow"><%=DataList(1,i)%></td>
<td height="30" class="classrow"><%=DataList(2,i)%></td>
<td height="30" class="classrow">{$Common("<%=DataList(2,i)%>")}</td>
<td class="classrow">
<a href="?action=mes_add&tag=<%=DataList(2,i)%>"><img src="images/icon_edit.gif" title=" <%=Lang_sys(51)%> " border="0"></a>
</td>
</tr>
<%
        Next
End If
%>
<tr>
	<td height="30" class="classfooter" align="right" colspan="5"><%=ors.ShowPageFoot(page)%></td>
</tr>
<tr>
<td colspan="6" class="classfaq">
  <div class="faq_main">
  <p class="faq_title"><%=Lang_sys(49)%></p>
  <%=Lang_Common(32)%>
</div>
</td>
</tr>
</tbody>
</table>
<script>tdshow("classtable");</script>
<%
end sub

Sub type_list()
		page = CheckNum(request("page"),1)
		pagenum = CheckNum(request("pagenum"),15)
		Dim ors
		Set ors=new Cls_vbsPage
		Set ors.Conn=conn
		With ors
		.PageSize=pagenum
		.PageName="Page"
		If IsSqlDataBase = 0 Then
				.DbType="AC"
		Else
				.DbType="MSSQL"
		End If
		.RecType=-1
		.Pkey="t_id"
		.Field="t_id,t_name,t_order,t_tag,t_show"
		.Table="[Lebi_Commontype]"
		sql = "t_type=1"
		.Condition=sql
		.OrderBy="t_order desc"
		End With
		DataCount=ors.RecCount()
		DataList=ors.ResultSet()
%>
<script language="JavaScript" type="text/JavaScript">
function ConfirmDel()
{
	if(confirm("<%=Lang_sys(64)%>"))
		return true;
	else
		return false;
}
function todel()
{

   var i = 0;
   var chkArr = document.getElementsByName("id");
   var page = document.getElementById("page").value;
   var param = "";
   for (i=0;i<chkArr.length;i++)
   if (chkArr[i].checked)
   param+=chkArr[i].value +",";
   if (param.length == 0)
   {
       alert("<%=Lang_sys(41)%>");
   }else{
       if(window.confirm("<%=Lang_sys(64)%>")){
           location="?action=type_del&id="+param+"&page="+page;
       }else return;
   }
}
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="classtable" class="classtable">
<form name="edit" method="post" action="?action=type_update">
<input type="hidden" name="page" value="<%= page %>">
<tr>
  <td colspan="2" height="30" class="classhead">
     <input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" title=" <%=Lang_sys(1)%> " align="absmiddle">
     <input type="image" title=" <%=Lang_sys(15)%> " onclick="location.href='javascript:todel();';return false;" src="lang/<%=LangFilePath%>/images/bt_delete.gif" align="absmiddle">
  </td>
  <td height="30" class="classhead" align="right" colspan="5"><%=QuickMenu("admin_common.asp|"& Lang_Menu(193) &"","?action=type_add|"& Lang_Common(16) &"")%></td>
 </tr>
<tr>
<td class="classtop" width="5%" height="30" title="<%=Lang_sys(4)%>" style="cursor:pointer;" onclick="location.href='javascript:selectall();';return false;"><%=Lang_sys(50)%></td>
<td width="45%" class="classtop"><%=Lang_Common(14)%></td>
<td width="20%" class="classtop"><%=Lang_Common(19)%></td>
<td width="10%" class="classtop" style="display:none"><%=Lang_Common(29)%></td>
<td width="10%" class="classtop"><%=Lang_Common(18)%></td>
<td width="10%" class="classtop"><%=Lang_Common(17)%></td>
</tr>
<%
If DataCount >0 Then
		For i = 0 To Ubound(DataList,2)
%>
<tr class="classrow">
<td width="5%" height="30" class="classrow"><input name="id" type="checkbox" value="<%=DataList(0,i)%>"><input name="t_id" type="hidden" value="<%=DataList(0,i)%>"></td>
<td height="30" class="classrow"><%=Trim(DataList(1,i))%></td>
<td class="classrow"><%=Trim(DataList(3,i))%></td>
<td class="classrow" style="display:none"><select name="t_show"><option value="0" <%=judge2(DataList(4,i),"0")%>><%=Lang_Common(31)%></option><option value="1" <%=judge2(DataList(4,i),"1")%>><%=Lang_Common(30)%></option></select></td>
<td class="classrow"><input name="t_order" type="text" id="t_order" value=<%=Trim(DataList(2,i))%> size="5" onkeyup="value=value.replace(/[^\d\.]/g,'');" class="form"></td>
<td class="classrow"><a href="?action=type_edit&id=<%=DataList(0,i)%>"><img src="images/icon_edit.gif" width="16" height="16" title=" <%=Lang_sys(51)%> " border="0"></a></td>
</tr>
<%
        Next
End If
%>
</form>
<tr>
	<td height="30" class="classfooter" align="right" colspan="6"><%=ors.ShowPageFoot(page)%></td>
</tr>
</tbody>
</table>
<script>tdshow("classtable");</script>
<%
End Sub

Sub type_add()
%>
		<script language="JavaScript">
		function CheckForm()
		{
			if (CheckEmpty('t_name<%= LanguageTxt(1) %>')){ShowMessage('t_name<%= LanguageTxt(1) %>','<%=Lang_Common(20)%>');return false;}
			if (CheckEmpty('t_tag')){ShowMessage('t_tag','<%=Lang_Common(24)%>');return false;}
		}
		</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="classtable">
  <form name="form1" method="post" action="?action=type_add_ok" onSubmit="return CheckForm();">
	<tr>
	  <td class="classhead" height="30" align="left">
		<input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle">
	</td>
	<td align="right" class="classhead">
	<%=QuickMenu("?action=type_list|"& Lang_Common(15) &"","|")%>
	</td>
   </tr>
	<tr>
	  <td class="classtop" colspan="2" height="30" align="left"><%=Lang_Common(16)%></td>
   </tr>
	<tr>
	<td class="classbg" colspan="2">
	<ul id="tablist">
	   <%For LangT = 1 To TotalLang%>
	   <li<%If LangT = 1 Then response.write(" class=""selected""") End If%>><a rel="tcontent<%= LangT %>" style="CURSOR:hand;"><%= LanguageName(LangT) %></a></li>
	   <%Next%>
	</ul>
	<div id="tabcontentcontainer">
	<%For LangT = 1 To TotalLang%>
	   <div id="tcontent<%= LangT %>" class="tabcontent">
	   <table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable_<%= LangT %>">
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(21)%></td>
			<td class="classrow"><input type="text" id="t_name<%= LanguageTxt(LangT) %>" name="t_name<%= LanguageTxt(LangT) %>" size="20" class="form" value=""> <span id="mes_t_name<%= LanguageTxt(LangT) %>"></span></td>
		 </tr>
		</table>
		</div>
		<script>tdshow("classtable_<%= LangT %>");</script>
	<%Next%>
	</div>
	<script>showtabcontent("tablist")</script>
	<ul id="tablistmain">
	   <li class="selected"><a rel=""><%=Lang_sys(66)%></a></li>
	</ul>
	<div id="tabcontentcontainer">
	<table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable">
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(23)%></td>
			<td class="classrow"><input type="text" name="t_tag" id="t_tag" size="15" value="" class="form"> <span id="mes_t_tag"></span></td>
		 </tr>
		 <tr class="classrow" style="display:none">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(28)%></td>
			<td class="classrow"><input type="radio" name="t_show" value="1" checked /><%=Lang_Common(30)%> <input type="radio" name="t_show" value="0" /><%=Lang_Common(31)%></td>
		 </tr>
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(22)%></td>
			<td class="classrow"><input type="text" name="t_order" size="5" value="1" class="form"></td>
		 </tr>
	</table>
	</div>
	<script>tdshow("classtable");</script>
	</td>
	</tr>
	<tr>
		<td colspan="2" align="left" height="30" class="classfooter">
		<input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"><input type="hidden" name="IsCheck" value="<%=IsCheck%>">
		</td>
	</tr>
   </form>
</table>
<%
End Sub

Sub type_edit()
		id=CheckNum(request("id"),0)
		set rs= conn.execute("Select * From [Lebi_Commontype] where t_id="& id &"")
		If Not rs.eof Then 
%>
		<script language="JavaScript">
		function CheckForm()
		{
			if (CheckEmpty('t_name<%= LanguageTxt(1) %>')){ShowMessage('t_name<%= LanguageTxt(1) %>','<%=Lang_Common(20)%>');return false;}
			if (CheckEmpty('t_tag')){ShowMessage('t_tag','<%=Lang_Common(24)%>');return false;}
		}
		</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="classtable">
  <form name="form1" method="post" action="?action=type_edit_ok" onSubmit="return CheckForm();">
	<tr>
	  <td class="classhead" height="30" align="left">
		<input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"><input type="hidden" name="id" value="<%= id %>">
	</td>
	<td align="right" class="classhead">
	<%=QuickMenu("","")%>
	</td>
   </tr>
	<tr>
	  <td class="classtop" colspan="2" height="30" align="left"><%=Lang_Common(3)%></td>
   </tr>
	<tr>
	<td class="classbg" colspan="2">
	<ul id="tablist">
	   <%For LangT = 1 To TotalLang%>
	   <li<%If LangT = 1 Then response.write(" class=""selected""") End If%>><a rel="tcontent<%= LangT %>" style="CURSOR:hand;"><%= LanguageName(LangT) %></a></li>
	   <%Next%>
	</ul>
	<div id="tabcontentcontainer">
	<%For LangT = 1 To TotalLang%>
	   <div id="tcontent<%= LangT %>" class="tabcontent">
	   <table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable_<%= LangT %>">
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(21)%></td>
			<td class="classrow"><input type="text" id="t_name<%= LanguageTxt(LangT) %>" name="t_name<%= LanguageTxt(LangT) %>" size="20" class="form" value="<%=rs("t_name" & LanguageTxt(LangT))%>"> <span id="mes_t_name<%= LanguageTxt(LangT) %>"></span></td>
		 </tr>
		</table>
		</div>
		<script>tdshow("classtable_<%= LangT %>");</script>
	<%Next%>
	</div>
	<script>showtabcontent("tablist")</script>
	<ul id="tablistmain">
	   <li class="selected"><a rel=""><%=Lang_sys(66)%></a></li>
	</ul>
	<div id="tabcontentcontainer">
	<table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable">
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(23)%></td>
			<td class="classrow"><input type="text" name="t_tag" id="t_tag" size="15" value="<%=rs("t_tag")%>" class="form"> <span id="mes_t_tag"></span></td>
		 </tr>
		 <tr class="classrow" style="display:none">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(28)%></td>
			<td class="classrow"><input type="radio" name="t_show" value="1" <%=judge(rs("t_show"),"1")%> /><%=Lang_Common(30)%> <input type="radio" name="t_show" value="0" <%=judge(rs("t_show"),"0")%> /><%=Lang_Common(31)%></td>
		 </tr>
		 <tr class="classrow">
			<td width="15%" height="30" class="classrow"><%=Lang_Common(22)%></td>
			<td class="classrow"><input type="text" name="t_order" size="5" value="<%=rs("t_order")%>" class="form"></td>
		 </tr>
	</table>
	</div>
	<script>tdshow("classtable");</script>
	</td>
	</tr>
	<tr>
		<td colspan="2" align="left" height="30" class="classfooter">
		<input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"><input type="hidden" name="IsCheck" value="<%=IsCheck%>">
		</td>
	</tr>
   </form>
</table>
<%
		End If 
		rs.close : Set rs = Nothing
End Sub

Sub mes_add()
		tag = safereplace(request("tag"))
%>
		<script language="javascript" type="text/javascript" src="ckeditor/ckeditor.js"></script>
          <table width="100%" border="0" cellspacing="0" cellpadding="0" class="classtable">
           <form method="post" action="?action=mes_add_ok" name="modi">
           <tr>
              <td height="30" align="left" class="classhead"><input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"><input type="hidden" name="tag" value="<%=tag%>"></td>
			<td align="right" class="classhead">
			<%=QuickMenu("","")%>
			</td>
           </tr>
           <tr>
              <td class="classtop" height="30" colspan="2"><%=Lang_Common(5)%></td>
           </tr>
			<tr>
			<td class="classbg" colspan="2">
			<ul id="tablist">
			   <%For LangT = 1 To TotalLang%>
			   <li<%If LangT = 1 Then response.write(" class=""selected""") End If%>><a rel="tcontent<%= LangT %>" style="CURSOR:hand;"><%= LanguageName(LangT) %></a></li>
			   <%Next%>
			</ul>
			<div id="tabcontentcontainer">
			<%For LangT = 1 To TotalLang%>
			   <div id="tcontent<%= LangT %>" class="tabcontent">
			   <table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable_<%= LangT %>">
				<tr class="classrow">
				  <td width="15%" class="classrow" valign="top" style="padding-top:6px;"><%=Lang_Common(26)%><div class="autosave"><span id="timemsg<%= LanguageTxt(LangT) %>"></span><br><span id="msg2<%= LanguageTxt(LangT) %>"></span><br><span id="msg<%= LanguageTxt(LangT) %>"></span></div><div class="autosave"><input type="checkbox" name="savepic<%= LanguageTxt(LangT) %>" value="1"><%=Lang_sys(71)%></div>
				  </td>
				  <td class="classrow">
					<script type="text/javascript">
					function showFCK<%= LanguageTxt(LangT) %>(){
						document.getElementById("btn_showFCK<%= LanguageTxt(LangT) %>").style.display = 'none' ;
						document.getElementById("ReHeightFCK<%= LanguageTxt(LangT) %>").style.display = 'none' ;
						CKEDITOR.replace('message<%= LanguageTxt(LangT) %>',{height:300});
					}
					</script>
					<textarea name="message<%= LanguageTxt(LangT) %>" id="message<%= LanguageTxt(LangT) %>" rows="22" cols="80" class="text"><%
					set rs = conn.execute("select c_content"& LanguageTxt(LangT) &" from [Lebi_Common] where t_tag='"& tag &"'")
					If Not rs.eof Then
						response.write rs(0)
					End If 
					rs.close : Set rs = Nothing 
					%></textarea>
					<span id="btn_showFCK<%= LanguageTxt(LangT) %>"><br /><input type="button" value="<%=Lang_sys(65)%>" onclick="showFCK<%= LanguageTxt(LangT) %>()" class="button"></span>
					<span id="ReHeightFCK<%= LanguageTxt(LangT) %>"><a href="javascript:u_Size(-10,'message<%= LanguageTxt(LangT) %>')"><img src="lang/<%=LangFilePath%>/images/tab/bt_close.gif" border='0'></a>&nbsp;<a href="javascript:u_Size(10,'message<%= LanguageTxt(LangT) %>')"><img src="lang/<%=LangFilePath%>/images/tab/bt_open.gif" border='0'></a></span>
					<%If Config_Lebi_Eshop(19) = "0" Then%><script>showFCK<%= LanguageTxt(LangT) %>()</script><%End If%>
					<SCRIPT LANGUAGE="JavaScript" src="Admin_autosave.asp?act=edit&type=help<%= LanguageTxt(LangT) %>&Lang=<%= LanguageTxt(LangT) %>"></SCRIPT>
				  </td>
			   </tr>
				</table>
				</div>
				<script>tdshow("classtable_<%= LangT %>");</script>
			<%Next%>
			</div>
			<script>showtabcontent("tablist")</script>
			</td>
			</tr>
               <tr>
                  <td class="classfooter" height="30" colspan="2" align="left">
                     <input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle">
                  </td>
               </tr>
            </form>
         </table>
<%
End Sub
%>