⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 admin_software.asp

📁 大型黄页系统,精美黄页flash演示,10m
💻 ASP
📖 第 1 页 / 共 4 页
字号:
		Rs("Decode") = Request.Form("Decode")
		Rs("isMember") = Request.Form("isMember")
		Rs("Homepage") = Request.Form("Homepage")
		Rs("Contact") = Request.Form("Contact")
		Rs("PreviewImg") = Request.Form("PreviewImg")
		Rs("Softimg") = Request.Form("Softimg")
		Rs("MoneyNum") = Request.Form("MoneyNum")
		Rs("isTop") = Request.Form("isTop")
		Rs("isUpdate") = 1
		Rs("isLock") = 0
		Rs("Errcode") = 0
		If Trim(Request.Form("updateTime")) = "yes" Then
			Rs("SoftTime") = DownsysClass.NowTime
		End If
		Rs.Update
		pubSoftID = Rs("softid")
		Rs.Close
		SQL = "update NC_softSort set isUpdate=1 where depth<>0 and sortid=" & strSortid(1)
		DownsysClass.Execute SQL
		SQL = "update NC_softSort set isUpdate=1 where depth=0 and rootid=" & strSortid(0)
		DownsysClass.Execute SQL
		'//////修改信息连接//////

		If Request.Form("totalPut") <> "" And Request.Form("SoftID") <> "" Then
			For i = 1 To Request.Form("totalPut")
				If Request("StrDownSite" & i & "") <> "" Then
					SQL = "select * from NC_softsite where ID=" & Request("ID" & i & "")
					SiteRs.Open SQL, Conn, 1, 3
					SiteRs("SiteName") = Request.Form("StRsiteName" & i & "")
					SiteRs("DownSite") = Request.Form("StrDownSite" & i & "")
					SiteRs("sortid") = strSortid(1)
					SiteRs("serverid") = Request.Form("server" & i & "")
					SiteRs.Update
					SiteRs.Close
				End If
			Next
		End If
		'//////添加信息连接地址//////
		If Request.Form("no") <> "" And Request.Form("SoftID") <> "" Then
			For i = 1 To Request("no")
				If Request("DownSite" & i & "") <> "" Then
					SQL = "select * from NC_softsite where (ID is null)"
					SiteRs.Open SQL, Conn, 1, 3
					SiteRs.addnew
					SiteRs("SiteName") = Request.Form("SiteName" & i & "")
					SiteRs("DownSite") = Request.Form("DownSite" & i & "")
					SiteRs("softid") = Request.Form("softid")
					SiteRs("sortid") = strSortid(1)
					SiteRs("serverid") = Request.Form("serverid" & i & "")
					SiteRs.Update
					SiteRs.Close
				End If
			Next
		End If
		'//////生成HTML//////
		If Request.form("isCreateHtml")="yes" then
			Dim DownloadClass
			Set DownloadClass = New Create_SoftInfo_Cls
			DownloadClass.CreateSoftInfo(pubSoftID)
			Set DownloadClass = Nothing
		End If
		NC_Admin.Succeed_Msg ("<li>修改" & Request.Form("softname") & "成功!</li>")
		Set Rs = Nothing
		Response.Write "<meta http-equiv=""refresh"" content=""2;url='admin_software.asp?ado="& mm &"'"">" & vbCrLf
	End If

End Sub


Private Sub batdel()
	Dim DownloadClass, DelSoftHtml, j
	DownsysClass.Execute ("delete from NC_SoftInfo where softid in (" & selSoftid & ")")
	DownsysClass.Execute ("delete from NC_SoftSite where softid in (" & selSoftid & ")")
	DownsysClass.Execute ("delete from NC_SoftEssay where softid in (" & selSoftid & ")")
       	If CInt(DownsysClass.Setting(5)) = 0 Then
        DelSoftHtml=split(selSoftid, ", ")
	Set DownloadClass = New Create_SoftInfo_Cls
	For j = 0 To Ubound(DelSoftHtml)
		DownloadClass.DelSoftInfo(DelSoftHtml(j))
	Next
		Set DownloadClass = Nothing
	End If
	'Response.Write ("批量删除操作成功!")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub batdele()
	Dim DownloadClass, DelSoftHtml, j
	DownsysClass.Execute ("update NC_SoftInfo set isLock=1,isUpdate=1 where softid in (" & selSoftid & ")")
       	If CInt(DownsysClass.Setting(5)) = 0 Then
        DelSoftHtml=split(selSoftid, ", ")
	Set DownloadClass = New Create_SoftInfo_Cls
	For j = 0 To Ubound(DelSoftHtml)
		DownloadClass.DelSoftInfo(DelSoftHtml(j))
	Next
		Set DownloadClass = Nothing
	End If
	'Response.Write ("你选择的文件已成功放入回收站!")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub batmove()
	Dim selSort
	selSort = Split(Trim(Request.Form("sortid")), ",")
	If Len(Request.Form("sortid")) <> 0 Then
		DownsysClass.Execute ("update NC_SoftInfo set rootid='" & selSort(0) & "',sortid='" & selSort(1) & "',SortName='" & selSort(2) & "',isUpdate=1 where softid in (" & selSoftid & ")")
		Response.Write ("批量移动操作成功,请重新生成移动的HTML文件!")
	Else
		Response.Write ("不能移动到一级分类,请选择正确的分类!")
	End If
End Sub

Private Sub isCommend()
	DownsysClass.Execute ("update [NC_SoftInfo] set isCommend=1 where softid in (" & selSoftid & ")")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub noCommend()
	DownsysClass.Execute ("update [NC_SoftInfo] set isCommend=0 where softid in (" & selSoftid & ")")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub upindate()
	DownsysClass.Execute ("update [NC_SoftInfo] set SoftTime=" & DownsysClass.SqlString & " where softid in (" & selSoftid & ")")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub isTop()
	DownsysClass.Execute ("update NC_SoftInfo set isTop=1 where softid in (" & selSoftid & ")")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub


Private Sub noTop()
	DownsysClass.Execute ("update NC_SoftInfo set isTop=0 where softid in (" & selSoftid & ")")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub

Private Sub BatCreateHtml()
	Dim DownloadClass, CreateSoftHtml, o, p
	o = 0
	Response.Write "<table width=""400"" border=""0"" cellspacing=""1"" cellpadding=""1"">" & vbCrLf
	Response.Write "<tr> " & vbCrLf
	Response.Write "<td bgcolor=000000>" & vbCrLf
	Response.Write " <table width=""400"" border=""0"" cellspacing=""0"" cellpadding=""1"">" & vbCrLf
	Response.Write "<tr> " & vbCrLf
	Response.Write "<td bgcolor=ffffff height=9><img src=""images/bar9.gif"" width=0 height=16 id=img2 name=img2 align=absmiddle></td></tr></table>" & vbCrLf
	Response.Write "</td></tr></table></td></tr><tr> " & vbCrLf
	Response.Write "<td align=center bgcolor=000000> <span id=txt2 name=txt2 style=""font-size:9pt"">0</span><span style=""font-size:9pt"">%</span>  <span id=txt3 name=txt3 style=""font-size:9pt"">0</span></td></tr>" & vbCrLf
	Response.Write "</table>" & vbCrLf
	Response.Flush
	CreateSoftHtml = Split(selSoftid, ",")
	p = Ubound(CreateSoftHtml)
	Set DownloadClass = New Create_SoftInfo_Cls
	Do while o <= p 
		DownloadClass.CreateSoftInfo(Cint(Trim(CreateSoftHtml(o))))
		Response.Write "<script>img2.width=" & Fix((o + 1) / (p + 1) * 400) & ";" & vbCrLf
		Response.Write "txt2.innerHTML=""生成进度:" & FormatNumber((o + 1) / (p + 1) * 100, 4, -1) & """;" & vbCrLf
		Response.Write "txt3.innerHTML=""共有 <B><font color=RED>" & p + 1 & "</font></B> 个  正在生成第 " & o + 1 & " 个"";" & vbCrLf
		Response.Write "img2.title=""(" & o + 1 & ")"";</script>" & vbCrLf
		o = o + 1
	Loop
	Response.Write "<script>txt3.innerHTML=""完成! 总共生成<B><font color=RED>" & p + 1 & "</font></B> 个文件"";</script>" & vbCrLf
	Response.Write "<script>img2.width=400;txt2.innerHTML=""100"";</script>"& vbCrLf
	Set DownloadClass = Nothing
	NC_Admin.Succeed_Msg ("完成! 总共生成<B><font color=RED>" & p + 1 & "</font></B> 个文件")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub

Private Sub showpage()
	If pagination = 0 Then
		If totalnumber Mod maxperpage = 0 Then
			n = totalnumber \ maxperpage
		Else
			n = totalnumber \ maxperpage + 1
		End If
		Response.Write "<table cellspacing=1 width='100%' border=0><form method=Post action=?clasid=" & Request("clasid") & "><tr><td align=center> " & vbCrLf
		Response.Write "<font color='red'>" & strSortName & "</font> "
		If CurrentPage < 2 Then
			Response.Write "共有信息 <font COLOR=#FF0000><strong>" & totalnumber & "</strong></font> 个&nbsp;首 页&nbsp;上一页&nbsp;"
		Else
			Response.Write "共有信息 <font COLOR=#FF0000><strong>" & totalnumber & "</strong></font> 个&nbsp;<a href=?page=1&clasid=" & Request("calsid") & ">首 页</a>&nbsp;"
			Response.Write "<a href=?page=" & CurrentPage - 1 & "&clasid=" & Request("clasid") & ">上一页</a>&nbsp;"
		End If
		If n - CurrentPage < 1 Then
			Response.Write "下一页&nbsp;尾 页" & vbCrLf
		Else
			Response.Write "<a href=?page=" & (CurrentPage + 1) & "&clasid=" & Request("clasid") & ">下一页</a>"
			Response.Write "&nbsp;<a href=?page=" & n & "&clasid=" & Request("clasid") & ">尾 页</a>" & vbCrLf
		End If
		Response.Write "&nbsp;页次:<strong><font color=red>" & CurrentPage & "</font>/" & n & "</strong>页 "
		Response.Write "&nbsp;转到:"
		If GotoPageType = 1 Then
			Response.Write "&nbsp;<select name='page' size='1' style=""font-size: 9pt"" onChange='javascript:submit()'>" & vbCrLf
			For ii = 1 To n
				Response.Write "<option value='" & ii & "' "
				If CurrentPage = CInt(ii) Then
					Response.Write "selected "
				End If
				Response.Write ">第" & ii & "页</option>"
			Next
			Response.Write "</select> " & vbCrLf
		Else
			Response.Write "<input name=page size=3> <input type=submit name=Submit value='GO→'>"
		End If
		Response.Write "</td></tr></FORM></table>" & vbCrLf
	Else
		n = CurrentPage
		If n < maxpagecount Then
			n = maxpagecount
		End If
		Response.Write "<table width=""100%"" border=""0"" align=""center"" cellpadding=""0"" cellspacing=""2"">"
		Response.Write " <tr><form method=""POST"" action='?clasid=" & Request("clasid") & "'>"
		Response.Write " <td align=""center""><font color='red'>" & strSortName & "</font> 共有信息 <font COLOR=#FF0000><strong>"
		Response.Write totalnumber
		Response.Write "</strong></font> 个 <a href=?page=1&clasid=" & Request("clasid") & " title=返回第一页><font face=""Webdings"">97</font></a> "
		For ii = pagestart To pageend
			If ii = 0 Then ii = 1
			If ii = CurrentPage Then
				Response.Write "<font color='red'><strong>" & ii & "</strong></font> "
			Else
				Response.Write "<a href=?page=" & ii & "&clasid=" & Request("clasid") & " title=第" & ii & "页><strong>" & ii & "</strong></a> "
			End If
		Next
		Response.Write "<a href=?page="
		Response.Write maxpagecount
		Response.Write "&clasid=" & Request("clasid") & " title=尾页><font face=""Webdings"">8:</font></a> 页次:<strong><font color=red>"
		Response.Write CurrentPage
		Response.Write "</font>/"
		Response.Write maxpagecount
		Response.Write "</strong>页 转到:"
		If GotoPageType = 1 Then
			Response.Write "&nbsp;<select name='page' size='1' style=""font-size: 9pt"" onChange='javascript:submit()'>" & vbCrLf
			For ii = 1 To n
				Response.Write "<option value='" & ii & "' "
				If CurrentPage = CInt(ii) Then
					Response.Write "selected "
				End If
				Response.Write ">第" & ii & "页</option>"
			Next
			Response.Write "</select> " & vbCrLf
		Else
			Response.Write "<input name=page size=3> <input type=submit name=Submit value='GO'>"
		End If
		Response.Write " </td></form></tr></table>" & vbCrLf
	End If

End Sub


Private Function SortingJumpMenu()
	Dim CacheJumpMenu
	Dim SQL
	Dim Rs1
	Dim i
		Dim SoftType,mm
	SoftType = Split(DownsysClass.Setting(35), ",")
	 mm = Trim(Request("ado"))
	DownsysClass.Name = "SortingJumpMenu"
	If DownsysClass.ObjIsEmpty() Then
		CacheJumpMenu = "<select onchange=""if(this.options[this.selectedIndex].value!=''){location=this.options[this.selectedIndex].value;}"">" & vbCrLf
		CacheJumpMenu = CacheJumpMenu & "<option value=admin_software.asp?ado="& mm &">≡全部信息列表≡</option>" & vbCrLf
		Set Rs1 = CreateObject("Adodb.recordset")
		SQL = "select * from NC_SoftSort order by rootid,orders"
		Rs1.Open SQL, Conn, 1, 1
		DownsysClass.SqlQueryNum = DownsysClass.SqlQueryNum + 1
		Do While Not Rs1.EOF
			CacheJumpMenu = CacheJumpMenu & "<option value=""admin_software.asp?ado="& mm &"&clasid=" & Rs1("sortid") & """ {SortID=" & Rs1("sortid") & "}"
			If Trim(Request("clasid")) <> "" Then
				If CLng(Request("clasid")) = Rs1("sortid") Then CacheJumpMenu = CacheJumpMenu & " selected"
			End If
			CacheJumpMenu = CacheJumpMenu & ">"
			If Rs1("depth") = 1 Then CacheJumpMenu = CacheJumpMenu & " ├ "
			If Rs1("depth") > 1 Then
				For i = 2 To Rs1("depth")
					CacheJumpMenu = CacheJumpMenu & " "
				Next
				CacheJumpMenu = CacheJumpMenu & " ├ "
			End If
			CacheJumpMenu = CacheJumpMenu & Rs1("SortName") & "</option>" & vbCrLf
			Rs1.movenext
		Loop
		Rs1.Close
		Set Rs1 = Nothing
		CacheJumpMenu = CacheJumpMenu & "</select>"
		DownsysClass.Value = CacheJumpMenu
	End If
	SortingJumpMenu = DownsysClass.Value
End Function

Private Function SelDownServer(intServerid, snid)
	Dim Rs_site
	Response.Write " <select name=""" & snid & """ size=""1"">"
	Response.Write "<option value=""0"""
	If intServerid = 0 Then Response.Write " selected"
	Response.Write ">↓请选择信息服务器↓</option>"
	Set Rs_site = CreateObject("adodb.recordset")
	SQL = "select serverid,ServerName,depth,rootid from NC_ServerSite where depth=0"
	Rs_site.Open SQL, Conn, 1, 1
	Do While Not Rs_site.EOF
		Response.Write "<option value=""" & Rs_site("rootid") & """"
		If intServerid = Rs_site("rootid") Then Response.Write " selected"
		Response.Write ">" & Rs_site(1) & "</option>"
		Rs_site.movenext
	Loop
	Rs_site.Close
	Set Rs_site = Nothing
	Response.Write "</select>"
End Function

Private Sub delsite()
	DownsysClass.Execute ("delete from NC_softsite where ID=" & Request("ID") & "")
	Response.redirect (Request.ServerVariables("HTTP_REFERER"))
End Sub
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -