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

📄 cf_admin_manage_do.asp

📁 支持多种播放器RealPlayer,MediaPlayer
💻 ASP
字号:
<%
'乘风电影程序
'制作:乘 风
'QQ:178575
'E-Mail:yliangcf@163.com
'开发网站:http://www.qqcf.com
'详细简介:http://www.qqcf.com/?action=list&list=cffilm
'上面有程序在线演示,安装演示,使用疑难解答,最新版本下载等内容
'因为这些内容可能时常更新,就没有放在程序里,请自己上网站上查看
'有完整版本的演示,包括如何实际整合Helix,Serv-u完全的实现在线播
'放和下载防盗链等
%>

<%
If Action="gotouser" Then
 UserName=ChkStr(Request("UserName"),1)

 Response.Cookies("CFFilmUserCookie")="" '如果以前存在Cookies则删除
 Response.Cookies("CFFilmUserCookie").Expires=Dateadd("n",-60,Now())
 Session("CFFilmUser")=UserName

 Response.Redirect("Manage.asp")
End If '转到用户页

If Action="sysmodifysave" Then
 Application("CFFilmMySet") = Empty'清空Asp里的配置
 Response.redirect "?Action=sysmodify"
End If

If Action="othersetmodifysave" Then
 Application("CFFilmMySet") = Empty'清空Asp里的配置
 Response.redirect "?Action=othersetmodify"
End If

If Action="sysrecsetsave" Then
 
 If RsSet("RegType=4") Then
  MyStr="<?"&vbcrlf
  MyStr=MyStr&"$dbhost="""&RsSet("SqlServerIP")&""";"&vbcrlf
  MyStr=MyStr&"$dbuser="""&RsSet("SqlServerLinkName")&""";"&vbcrlf
  MyStr=MyStr&"$dbpwd="""&RsSet("SqlServerLinkPassword")&""";"&vbcrlf
  MyStr=MyStr&"$dbname="""&RsSet("SqlServerDbName")&""";"&vbcrlf
  MyStr=MyStr&"$dbport=""3306"";"&vbcrlf
  
  MyStr=MyStr&"$saveregtable="""&RsSet("saveregtable")&""";"&vbcrlf
  MyStr=MyStr&"$saveregusername="""&RsSet("saveregusername")&""";"&vbcrlf
  MyStr=MyStr&"$saveregpassword="""&RsSet("saveregpassword")&""";"&vbcrlf
  MyStr=MyStr&"$passwordtype="&RsSet("passwordtype")&";"&vbcrlf

  MyStr=MyStr&"$conn_user = mysql_connect($dbhost."":"".$dbport,$dbuser,$dbpwd);"&vbcrlf
  MyStr=MyStr&"if (!$conn_user) die (""对不起,发生错误! 请检查CF_phpuserrec.php中数据库的配置是否正确!"");"&vbcrlf
  MyStr=MyStr&"mysql_select_db($dbname,$conn_user);"&vbcrlf
  MyStr=MyStr&"?>"
  
  Set fso = Server.CreateObject("Scripting.FileSystemObject")'php数据库接口文件
  Set fout = fso.Createtextfile(server.mappath("CF_phpuserrec.php"),true)
  fout.writeline MyStr
  
  MyCode=FSOFileRead("CF_RecLogin.asp")
  MyArray=Split(MyCode,"php_rec_login_code")

  Set fout = fso.Createtextfile(server.mappath("CF_phplogin.php"),true)'php登陆文件
  fout.writeline MyArray(1)
 
  Set fout = fso.Createtextfile(server.mappath("CF_Temp.asp"),true)'php登陆临时文件
  fout.writeline ""
 End If
 
 If RsSet("RegType=4")=1 Then Call AlertUrl("修改成功","?Action=sysrecset")
 If RsSet("RegType=4")=2 Or RegType=3 Then Call AlertUrl("修改成功,请查看数据库接口设置是否正确的测试结果!","?Action=sysrecset#sysrecsetresultview")
 If RsSet("RegType=4")=4 Then Call AlertUrl("修改成功,请在系统首页用原网站用户登陆,能登陆则表示设置正确","?Action=sysrecset")
End If'接口设置

If Action="sqlexesave" Then
 If AdminOnlineExecSql=0 Then Call AlertBack("Conn.asp里设置了系统禁止在线执行Sql语句",1)
 
 Pwd=GoBack(ChkStr(Trim(Request("Pwd")),1),"请输入确认密码")

 Set Rs= Server.CreateObject("Adodb.RecordSet")
 Sql="Select Pwd From CFFilm_Admin"
 Rs.Open Sql,Conn,3,2
 If Md5(Pwd,1)<>Rs("Pwd") Then Call AlertBack("确认密码输入有错误",1)
 
 Sql = Request.Form("Sql")
 Conn.Execute(Sql)
  
 Call AlertBack("执行成功",1)
End If

If Action="dbys" Then
 YsDbName="backup_"&year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&".mdb"
 TgDbName="backup_"&year(now)&month(now)&day(now)&hour(now)&minute(now)&(second(now)+1)&".mdb"

 Set Fs = Server.CreateObject("Scripting.FileSystemObject")
 Fs.copyfile Server.MapPath(DbPath),Server.MapPath("data\"&YsDbName)
 
  Const JET_3X = 4
  Set Engine = CreateObject("JRO.JetEngine")
  on error resume next
  Engine.CompactDatabase "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("data\"&YsDbName) , "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("data\"&TgDbName)

  Fs.CopyFile Server.MapPath("data\"&TgDbName),Server.MapPath(DbPath)
  
 Call AlertBack("压缩成功",1)
End If

If Action="dbbackup" Then
 Set Fs = Server.CreateObject("Scripting.FileSystemObject")
 Fs.copyfile Server.MapPath(DbPath),Server.MapPath("data\backup_"&year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&".mdb")
 Call AlertBack("备份数据库成功!",1)
End If '数据库备份结束


If Action="dbdel" Then
 DbMc=ChkStr(Request("DbMc"),1)
 
If Lcase(StrReverse(Left(StrReverse(DbMc),4)))<>".mdb" Then Call Alertback("只能删除扩展名为mdb的数据库文件",1)

 Set Fs = Server.CreateObject("Scripting.FileSystemObject")
 Set Os = Fs.GetFile(Server.mappath("data/"&DbMc))
 Os.Delete


 Call AlertBack("成功删除!",1)
End If

If Action="adminlogout" Then
 Session("CFFilmAdmin")=""
 Response.Cookies("CFFilmAdminCooKie")=""
 Response.Cookies("CFFilmAdminCooKie").Expires=Dateadd("n",-60,Now())
 Response.Redirect "Admin.asp"
End If
%>

⌨️ 快捷键说明

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