<!--#include file="../Inc.asp"-->
<!--#include file="../ydzq1.asp"-->
<!--#include file="../../inc/char.asp"-->
<%Call Head()
Call saycardd("添加栏目类别")
  IF KEYs<>1 then
  Call Error("你的权限不足！")
  end if
dim id,lxl,class1,num,relid,cent,vipin,lxxx,url
 id= cint(request("id"))
        lxl= cint(request("lxl"))
        class1=request("class1")
        relid=request("relid")
        num=request("num")
        cent=request("cent")
        mm=request("mm")
        vipin=request("vipin")
		lxxx=request("lxxx")
		password=request.form("password")

Set rs = Server.CreateObject("ADODB.Recordset")
rs.Open "SELECT * FROM users where id="&myid,conn,1,1
if rs("mm")<>password then

  Call Error(" 密码不正确")

end if
  rs.close
  set rs=Nothing

        if mm="" then mm="0"
if class1="" then
        Call Error("栏目名称不能为空！")
        end if
if relid="" or IsNumeric(relid)=False then
 relid=0
  end if
if vipin="" or IsNumeric(vipin)=False then
 vipin=0
  end if
if num="" or IsNumeric(num)=False then
 num=0
  end if
  if cent="" or IsNumeric(cent)=False then
 cent=0
  end if
        pid=request.form("pid")
if pid="" or IsNumeric(pid)=False then
  Call Error("排序无效！")
  end if
        br=request.form("br")
if br="" or IsNumeric(br)=False then
  Call Error("换行无效！")
  end if
  lx=request.form("lx")
if lx="" or IsNumeric(lx)=False then
  Call Error("类型无效！")
  end if
        parent=request.form("parent")
        if parent="" or IsNumeric(parent)=False then parent=0
        lid=request.form("lid")
 if lid <>"" then
if IsNumeric(lid)=False then
  Call Error("ID无效！")
  end if
  end if
        img=request.form("img")
		If lxxx<>"" Then
		If lxxx=10 Then
		url=("/bbs/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=11 Then
        url=("/bbs/game/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=12 Then
        url=("/qtwap/sms/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=13 Then
        url=("/xhdq/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=14 Then
        url=("/bbs/zone.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=15 Then
        url=("/bbs/city.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=16 Then
        url=("/bbs/chat/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=17 Then
        url=("/bbs/cw/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=18 Then
        url=("/bbs/blog/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=19 Then
        url=("/bbs/xy/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=20 Then
        url=("/shop/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=21 Then
        url=("/guestbook.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=22 Then
        url=("/link/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=23 Then
        url=("/foryou/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=24 Then
        url=("/bbs/1say/wxsc/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=25 Then
        url=("/bbs/history/?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=26 Then
        url=("/bbs/bbslist.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=27 Then
        url=("/bbs/photo.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=28 Then
        url=("/bbs/sqbz/index.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=29 Then
        url=("/bbs/bankcl.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=30 Then
        url=("/bbs/marry/index.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=31 Then
        url=("/bbs/myfriend.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=32 Then
        url=("/bbs/show.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=33 Then
        url=("/bbs/qian.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=34 Then
        url=("/bbs/jia/hua.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=35 Then
        url=("/bbs/feel.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=36 Then
        url=("/bbs/xunzhang.asp?sid=[sid]&amp;saytk=[saytk]")
		ElseIf lxxx=37 Then
        url=("/bbs/jia/index.asp?sid=[sid]&amp;saytk=[saytk]")


		End If
		else
        url=request("url")
		End if
        wmltxt=request("wmltxt")
        active=request("active")
        opera=request("opera")
dim conngamepb,conngamepbstr
conngamepbstr="DBQ="+server.mappath("/shujuku/chajianshujuku/saytk_pb/saytk_pb")+";DefaultDir=;DRIVER={Microsoft Access Driver (*.mdb)};"
set conngamepb=server.createobject("ADODB.connECTION")
conngamepb.open conngamepbstr

	set rs=server.createobject("adodb.recordset")
	sql="select * from gameclass" 
	rs.open sql,conngamepb,2,3
	rs.addnew
	rs("class")=class1
        rs("pid")=pid
        rs("br")=br
        rs("lx")=lx
        rs("parent")=parent
        rs("lid")=lid
        rs("relid")=relid
        rs("cent")=cent
        rs("prentmm")=mm
        rs("vipin")=vipin
        rs("img")=img
        rs("url")=url
        rs("wmltxt")=wmltxt
        rs("active")=active
        rs("opera")=opera
        rs("num")=num
	rs.update
	rs.close
	set rs=nothing
	conngamepb.close
	set conngamepb=nothing
%>
栏目添加成功!
<br/>----------<br/>
<%if id<>0 then %>
<a href="Clist.asp?saytk=<%=saytk%>&amp;sid=<%=sid%>&amp;id=<%=id%>&amp;lx=<%=lxl%>">[栏目分类]</a><br/>
<%end if%>
<a href='class.asp?saytk=<%=saytk%>&amp;sid=<%=sid%>'>[栏目分类]</a><br/>
<a href="/bbs/show.asp?saytk=<%=saytk%>&amp;sid=<%=sid%>">返回我的地盘</a><br/>
<%call headsay()%>
