Flink_SysPara.asp
上传用户:jisenq
上传日期:2014-06-29
资源大小:7216k
文件大小:5k
源码类别:

数据库编程

开发平台:

ASP/ASPX

  1. <% Option Explicit %>
  2. <!--#include file="../../FS_Inc/Const.asp" -->
  3. <!--#include file="../../FS_InterFace/MF_Function.asp" -->
  4. <!--#include file="../../FS_InterFace/NS_Function.asp" -->
  5. <!--#include file="../../FS_Inc/Function.asp" -->
  6. <%
  7. Response.Buffer = True
  8. Response.Expires = -1
  9. Response.ExpiresAbsolute = Now() - 1
  10. Response.Expires = 0
  11. Response.CacheControl = "no-cache"
  12. Dim Conn,obj_sys_Rs,tmp_type,strShowErr
  13. Dim IsOpen,IsRegister,ArrSize,Content,isLock,Update_type
  14. MF_Default_Conn
  15. MF_Session_TF
  16. if not MF_Check_Pop_TF("FL002") then Err_Show
  17. set obj_sys_Rs = Server.CreateObject(G_FS_RS)
  18. obj_sys_Rs.open "select top 1 id,IsOpen,IsRegister,ArrSize,Content,isLock from FS_FL_SysPara",Conn,1,3
  19. if not obj_sys_Rs.eof then
  20. IsOpen = obj_sys_Rs("IsOpen")
  21. IsRegister = obj_sys_Rs("IsRegister")
  22. ArrSize = obj_sys_Rs("ArrSize")
  23. Content = obj_sys_Rs("Content")
  24. isLock = obj_sys_Rs("isLock")
  25. Update_type = "edit"
  26. else
  27. IsOpen = 1
  28. IsRegister =0
  29. ArrSize = "88,31"
  30. Content = "申请注册"
  31. isLock = 1
  32. Update_type = "add"
  33. end if
  34. if Request.Form("Edit_save")<>"" then
  35. dim obj_sys_Rs_1,arr_tmp
  36. if trim(Request.Form("ArrSize"))<>"" then
  37. if instr(Request.Form("ArrSize"),",")=0 then
  38. strShowErr = "<li>Logo尺寸格式不对</li>"
  39. Response.Redirect("../error.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=Flink/Flink_SysPara.asp")
  40. Response.end
  41. end if
  42. else
  43. strShowErr = "<li>请填写LOGO尺寸</li>"
  44. Response.Redirect("../error.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=Flink/Flink_SysPara.asp")
  45. Response.end
  46. end if
  47. set obj_sys_Rs_1 = Server.CreateObject(G_FS_RS)
  48. obj_sys_Rs_1.open "select top 1 id,IsOpen,IsRegister,ArrSize,Content,isLock from FS_FL_SysPara",Conn,1,3
  49. if trim(Request.Form("Edit_save"))="add" then
  50. obj_sys_Rs_1.addnew
  51. end if
  52. if trim(Request.Form("isopen"))<>"" then:obj_sys_Rs_1("isOpen") = 1:else:obj_sys_Rs_1("isOpen") = 0:end if
  53. if trim(Request.Form("IsRegister"))<>"" then:obj_sys_Rs_1("IsRegister") = 1:else:obj_sys_Rs_1("IsRegister") = 0:end if
  54. if trim(Request.Form("isLock"))<>"" then:obj_sys_Rs_1("isLock") = 1:else:obj_sys_Rs_1("isLock") = 0:end if
  55. obj_sys_Rs_1("ArrSize") = Request.Form("ArrSize")
  56. obj_sys_Rs_1("Content") = Request.Form("Content")
  57. obj_sys_Rs_1.update
  58. obj_sys_Rs_1.close:set obj_sys_Rs_1=nothing
  59. strShowErr = "<li>修改成功</li>"
  60. Response.Redirect("../Success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=Flink/Flink_SysPara.asp")
  61. Response.end
  62. end if
  63. %>
  64. <html>
  65. <HEAD>
  66. <TITLE>FoosunCMS</TITLE>
  67. <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
  68. </HEAD>
  69. <link href="../images/skin/Css_<%=Session("Admin_Style_Num")%>/<%=Session("Admin_Style_Num")%>.css" rel="stylesheet" type="text/css">
  70. <BODY>
  71. <table width="98%" border="0" align="center" cellpadding="4" cellspacing="1" class="table">
  72.   <tr> 
  73.     <td align="left" colspan="2" class="xingmu">参数设置</td>
  74.   </tr>
  75. </table>
  76.   
  77. <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  78.   <form name="form1" method="post" action="">
  79.     <tr> 
  80.       <td width="26%" class="hback"> 
  81.         <div align="right">是否开放友情连接申请</div></td><td width="74%" class="hback"><input name="IsOpen" type="checkbox" id="IsOpen" value="1" <%if IsOpen=1 then response.Write("checked")%>>
  82.         是</td>
  83.     </tr>
  84.     <tr> 
  85.       <td class="hback"> 
  86.         <div align="right">注册会员才能申请</div></td><td class="hback"><input name="IsRegister" type="checkbox" id="IsRegister" value="1" <%if IsRegister=1 then response.Write("checked")%>>
  87.         是</td>
  88.     </tr>
  89.     <tr> 
  90.       <td class="hback"> 
  91.         <div align="right">友情连接图片最大及最小尺寸</div></td><td class="hback"><input name="ArrSize" type="text" id="ArrSize" value="<%= arrsize%>">
  92.         格式:88,31</td>
  93.     </tr>
  94.     <tr> 
  95.       <td class="hback"> 
  96.         <div align="right">申请连接须知</div></td><td class="hback"><textarea name="Content" rows="5" id="Content"  style="width:60%"><% = content %></textarea></td>
  97.     </tr>
  98.     <tr> 
  99.       <td class="hback"> 
  100.         <div align="right">申请的连接是否要审核</div></td><td class="hback"><input name="isLock" type="checkbox" id="isLock" value="1" <%if isLock=1 then response.Write("checked")%>>
  101.         是</td>
  102.     </tr>
  103.     <tr>
  104.       <td class="hback"> 
  105.         <div align="right"></div></td><td class="hback"><input type="submit" name="Submit" value="更新参数">
  106.         <input name="Edit_save" type="hidden" id="Edit_save" value="<% = Update_type %>">
  107.         <input type="reset" name="Submit2" value="重置"></td>
  108.     </tr>
  109.   </form>
  110. </table>
  111. </body>
  112. </html>