Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
Deal_pro.asp
Package: pinke2010.rar [view]
Upload User: pengwei803
Upload Date: 2021-02-10
Package Size: 3311k
Code Size: 7k
Category:
WEB(ASP,PHP,...)
Development Platform:
HTML/CSS
- <!--#include file="../Ku_inc/Ku_sql.asp"-->
- <!--#include file="../Ku_inc/Ku_config.asp"-->
- <!--#include file="Ku_conn.asp"-->
- <!--#include file="../Ku_inc/inc.asp"-->
- <!-- #include file="Session.asp"-->
- <%
- if request("action")="addpro" then
- title=request("title")
- gg=request("gg")
- tj=request("tj")
- pic1=request("pic1")
- BigClassName=request("BigClassName")
- SmallClassName=request("SmallClassName")
- content=request("content")
- set rs=server.createobject("adodb.recordset")
- sql="select * from ku_pro"
- rs.open sql,conn,1,3
- rs.addnew
- rs("title")=title
- rs("gg")=gg
- rs("content")=content
- rs("pic1")=Replace(pic1,left(pic1,3),"")
- rs("tj")=tj
- rs("bigclassname")=BigClassName
- rs("SmallClassName")=smallClassName
- rs.update
- rs.close
- set rs=nothing
- conn.close
- set conn=nothing
- response.Write("<script>alert(""添加产品成功!"");location.href=""Pro_list.asp"";</script>")
- end if
- %>
- <%
- if request("action")="editprobig" then
- BigClassID=trim(Request("BigClassID"))
- NewBigClassName=trim(Request("NewBigClassName"))
- oldBigClassName=trim(Request("oldBigClassName"))
- if NewBigClassName="" then
- Response.Write "<script>alert(""类别不能为空!"");location.href=""javascript:history.back()"";</script>"
- else
- Set rs=Server.CreateObject("Adodb.RecordSet")
- rs.Open "Select * from ku_bigclass where BigClassID="&BigClassID,conn,1,3
- rs("BigClassName")=NewBigClassName
- rs.update
- rs.Close
- set rs=Nothing
- conn.execute "Update ku_SmallClass set BigClassName='" & NewBigClassName & "' where BigClassName='" & oldBigClassName & "'"
- conn.execute "Update ku_pro set BigClassName='" & NewBigClassName & "' where BigClassName='" & oldBigClassName & "'"
- response.Write("<script>alert(""修改成功!"");location.href=""Ku_ProClass.asp"";</script>")
- end if
- end if
- %>
- <%
- if request("action")="editprosmall" then
- SmallClassID=trim(Request("SmallClassID"))
- BigClassName=trim(Request.form("BigClassName"))
- SmallClassName=trim(Request.form("SmallClassName"))
- oldSmallClassName=trim(request.form("oldSmallClassName"))
- if SmallClassName="" then
- Response.Write "<script>alert(""类别不能为空!"");location.href=""javascript:history.back()"";</script>"
- else
- Set rs=Server.CreateObject("Adodb.RecordSet")
- rs.Open "Select * from ku_SmallClass where SmallClassID="&SmallClassID&"",conn,1,3
- rs("SmallClassName")=SmallClassName
- rs.update
- rs.Close
- set rs=Nothing
- conn.execute "Update news set ku_SmallClassName='" & SmallClassName & "' where SmallClassName='" & OldSmallClassName & "'"
- response.write "<script language='javascript'>" & chr(13)
- response.write "alert('修改成功!');" & Chr(13)
- response.write "window.document.location.href='Ku_Proclass.asp';"&Chr(13)
- response.write "</script>" & Chr(13)
- Response.End
- end if
- end if
- %>
- <%
- if request("action")="delsmallclass" then
- SmallClassID=trim(Request("SmallClassID"))
- SmallClassName=trim(Request("SmallClassName"))
- if SmallClassID<>"" then
- sql="delete from ku_SmallClass where SmallClassID="&Cint(SmallClassID)&""
- conn.Execute sql
- sql="delete from ku_pro where SmallClassName='" & SmallClassName & "'"
- conn.Execute sql
- end if
- response.redirect "Ku_Proclass.asp"
- end if
- %>
- <%
- if Request("Action")="addsmall" then
- BigClassName=trim(request("BigClassName"))
- SmallClassName=trim(request("SmallClassName"))
- Set rs=Server.CreateObject("Adodb.RecordSet")
- rs.open "Select * From ku_smallclass Where BigClassName='" & BigClassName & "' AND SmallClassName='" & SmallClassName & "'",conn,1,3
- if (rs.eof and rs.bof) then
- rs.addnew
- rs("BigClassName")=BigClassName
- rs("SmallClassName")=SmallClassName
- rs.update
- rs.Close
- set rs=Nothing
- response.Write("<script>alert(""添加成功!"");location.href=""Ku_ProClass.asp"";</script>")
- else
- Response.Write "<script>alert(""已经存在小类,请重新填写!"");location.href=""javascript:history.back()"";</script>"
- end if
- end if
- %>
- <%
- if Request("Action")="addbig" then
- BigClassName=trim(request("BigClassName"))
- Set rs=Server.CreateObject("Adodb.RecordSet")
- rs.open "Select * From ku_BigClass Where BigClassName='" & BigClassName & "'",conn,1,3
- if (rs.eof and rs.bof) then
- rs.addnew
- rs("BigClassName")=BigClassName
- rs.update
- rs.Close
- set rs=Nothing
- response.Write("<script>alert(""添加成功!"");location.href=""Ku_ProClass.asp"";</script>")
- else
- Response.Write "<script>alert(""已经存在大类,请重新填写!"");location.href=""javascript:history.back()"";</script>"
- end if
- end if
- %>
- <%
- if request("action")="delbigclass" then
- BigClassName=trim(Request("BigClassName"))
- if BigClassName<>"" then
- sql="delete from Ku_bigclass where BigClassName='" & BigClassName & "'"
- conn.Execute sql
- sql="delete from Ku_smallclass where BigClassName='" & BigClassName & "'"
- conn.Execute sql
- sql="delete from Ku_pro where BigClassName='" & BigClassName & "'"
- conn.Execute sql
- end if
- response.redirect "Ku_proclass.asp"
- end if
- %>
- <%
- if request("action")="del" then
- if Trim(Request("ID"))="" then
- FoundErr=True
- Message=Message & "<li>请您选择要删除的信息!</li>"
- else
- call Del()
- end if
- if FoundErr<>True then
- Sub Del()
- '删除信息
- sql = "delete from ku_pro where ID in ("& Trim(Request("ID")) &")"
- conn.execute (sql)
- End Sub
- '成功提示
- call performMsgpro("操作成功!","")
- end if
- if FoundErr=True then
- call ErrMsg(Message)
- end if
- end if
- %>
- <%
- if request("action")="tisheng" then
- if Trim(Request("ID"))="" then
- FoundErr=True
- Message=Message & "<li>请您选择要操作的信息!</li>"
- else
- call strPeak()
- end if
- if FoundErr<>True then
- Sub strPeak()
- adoSQL="update ku_pro set addtime=now() where ID=" & Trim(Request("ID")) & ""
- conn.execute(adoSQL)
- End Sub
- '成功提示
- call performMsgpro("操作成功!","")
- end if
- if FoundErr=True then
- call ErrMsg(Message)
- end if
- end if
- %>
- <%
- if request("action")="add" then
- name=Checkin(trim(Request.form("mingcheng")))
- If name="" Then
- Response.Write "<script>alert(""分类名称不能为空!"");location.href=""javascript:history.back()"";</script>"
- Response.end()
- end if
- set rs=server.createobject("adodb.recordset")
- sql="select * from ku_newskind where name='"&name&"'"
- rs.open sql,conn,1,3
- if (rs.eof and rs.bof) then
- rs.addnew
- rs("name")=name
- rs.update
- rs.close
- response.Write("<script>alert(""添加成功!"");location.href=""News_kind.asp"";</script>")
- else
- response.Write("<script>alert(""分类已存在!"");location.href=""News_kind.asp"";</script>")
- end if
- end if
- %>
- <%
- if request("action")="edit" then
- name=Checkin(trim(Request.form("mingcheng")))
- id=request("id")
- If name="" Then
- Response.Write "<script>alert(""分类名称不能为空!"");location.href=""javascript:history.back()"";</script>"
- Response.end()
- end if
- set rs=server.createobject("adodb.recordset")
- sql="select * from ku_newskind where id="&id
- rs.open sql,conn,1,3
- rs("name")=name
- rs.update
- rs.close
- response.Write("<script>alert(""修改成功!"");location.href=""News_kind.asp"";</script>")
- end if
- %>