admin_InputFile.asp
上传用户:comthink
上传日期:2021-05-06
资源大小:1280k
文件大小:6k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

HTML/CSS

  1. <!-- #include file="conn.asp" -->
  2. <!-- #include file="inc/const.asp" -->
  3. <title><%=txl_info(0)%>--管理页面</title>
  4. <!--#include file="inc/admin_css.asp"-->
  5. <meta NAME=GENERATOR Content="Microsoft FrontPage 3.0" CHARSET=GB2312>
  6. <BODY leftmargin="0" bottommargin="0" rightmargin="0" topmargin="0" marginheight="0" marginwidth="0" bgcolor="#DDEEFF">
  7. <%
  8. if session("flag")="" then
  9. Errmsg=Errmsg+"<br>"+"<li>本页面为管理员专用,请<a href=admin_index.asp target=_top>登陆</a>后进入。<br><li>您没有管理本页面的权限。"
  10. call txl_error()
  11. else
  12. call main()
  13. conn.close
  14. set conn=nothing
  15. end if
  16. sub main()
  17. %>
  18. <table width="95%" border="0" cellspacing="1" cellpadding="3"  align=center class="tableBorder">
  19. <tr> 
  20. <th width="100%" class="tableHeaderText" colspan=2 height=25>同学录初始信息设置
  21. </th>
  22. </tr>
  23. <tr>
  24. <td class="txlrow" colspan=2>
  25. <p><B>注意</B>:在这里您可以调整部分同学录信息提示,其中部分功能可能需要FSO的支持,如果不支持FSO文件写入功能,请直接手动修改相关文件。
  26. </td>
  27. </tr>
  28. <tr>
  29. <td class="txlrow">
  30. <B>操作选项</B></td>
  31. <td class="txlrow"><a href="admin_inputfile.asp">注册条款修改</a> | <a href="?action=email">注册邮件内容修改</a> | <a href="?action=sms">注册发送短信修改</a>
  32. </td>
  33. </tr>
  34. </table>
  35. <p></p>
  36. <%
  37. select case request("action")
  38. case "email"
  39. call email()
  40. case "sms"
  41. call sms()
  42. case else
  43. call reg()
  44. end select
  45. end sub
  46. sub reg()
  47. dim objFSO
  48. dim fdata
  49. dim objCountFile
  50. on error resume next
  51. Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
  52. if request("save")="" then
  53. Set objCountFile = objFSO.OpenTextFile(Server.MapPath("inc/reg_txt.asp"),1,True)
  54. If Not objCountFile.AtEndOfStream Then fdata = objCountFile.ReadAll
  55. else
  56. fdata=request("fdata")
  57. Set objCountFile=objFSO.CreateTextFile(Server.MapPath("inc/reg_txt.asp"),True)
  58. objCountFile.Write fdata
  59. end if
  60. objCountFile.Close
  61. Set objCountFile=Nothing
  62. Set objFSO = Nothing
  63. if err.number<>0 then
  64. response.write "您的空间不支持FSO,请同您的空间商联系,或者查看相关权限设置<br>"&Err.Description&""
  65. response.end
  66. end if
  67. %> 
  68. <form method=post action="?action=reg">
  69. <table width="95%" border="0" cellspacing="1" cellpadding="3"  align=center class="tableBorder">
  70. <tr> 
  71. <th width="100%" class="tableHeaderText" height=25>注册条款修改
  72. </th>
  73. </tr>
  74. <tr>
  75. <td class="txlrow">
  76. 注意:文件将被保存在你安装目录下的<B>inc/reg_txt.asp</B>里,如果您的空间不支持<font color="red">FSO</font>,请直接编辑该文件!内容中带有《%%》的部分不要进行编辑
  77. </td>
  78. </tr>
  79. <tr>
  80. <td class="txlrow">
  81. <textarea name="fdata" cols="100" rows="15"><%=fdata%></textarea>
  82. </td>
  83. </tr>
  84. <tr>
  85. <td class="txlrow">
  86. <input type="reset" name="Reset" value="重新修改">
  87. <input type="submit" name="save" value="提交修改"> 当前文件路径:<b><%=Server.MapPath("inc/reg_txt.asp")%></b>
  88. </td>
  89. </tr>
  90. </form>
  91. </table>
  92. <%
  93. end sub
  94. sub email()
  95. dim objFSO
  96. dim fdata
  97. dim objCountFile
  98. on error resume next
  99. Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
  100. if request("save")="" then
  101. Set objCountFile = objFSO.OpenTextFile(Server.MapPath("inc/email_txt.asp"),1,True)
  102. If Not objCountFile.AtEndOfStream Then fdata = objCountFile.ReadAll
  103. else
  104. fdata=request("fdata")
  105. Set objCountFile=objFSO.CreateTextFile(Server.MapPath("inc/email_txt.asp"),True)
  106. objCountFile.Write fdata
  107. end if
  108. objCountFile.Close
  109. Set objCountFile=Nothing
  110. Set objFSO = Nothing
  111. if err.number<>0 then
  112. response.write "您的空间不支持FSO,请同您的空间商联系,或者查看相关权限设置<br>"&Err.Description&""
  113. response.end
  114. end if
  115. %> 
  116. <form method=post action="?action=email">
  117. <table width="95%" border="0" cellspacing="1" cellpadding="3"  align=center class="tableBorder">
  118. <tr> 
  119. <th width="100%" class="tableHeaderText" height=25>注册条款修改
  120. </th>
  121. </tr>
  122. <tr>
  123. <td class="txlrow">
  124. 注意:文件将被保存在你安装目录下的<B>inc/email_txt.asp</B>里,如果您的空间不支持<font color="red">FSO</font>,请直接编辑该文件!<BR>
  125. <B>修改说明</B>:<BR>
  126. ①修改本文件需要一定HTML和ASP代码知识,如果您不会,请不要随意改动<BR>
  127. ②文件中带有《%%》和"&&"之类的字符不要随意做改动<BR>
  128. ③mailbody变量是邮件内容变量,htmlencode(username)是用户名,getpass是密码,Copyright是版权,Version版本信息<BR>
  129. ④需要增加行和内容可以回车后采用这种方式:mailbody=mailbody & "添加内容"<BR>
  130. ⑤HTML中的双引号建议改成单引号,也可以不要引号或者加两个双引号都可以
  131. </td>
  132. </tr>
  133. <tr>
  134. <td class="txlrow">
  135. <textarea name="fdata" cols="100" rows="15"><%=fdata%></textarea>
  136. </td>
  137. </tr>
  138. <tr>
  139. <td class="txlrow">
  140. <input type="reset" name="Reset" value="重新修改">
  141. <input type="submit" name="save" value="提交修改"> 当前文件路径:<b><%=Server.MapPath("inc/email_txt.asp")%></b>
  142. </td>
  143. </tr>
  144. </form>
  145. </table>
  146. <%
  147. end sub
  148. sub sms()
  149. dim objFSO
  150. dim fdata
  151. dim objCountFile
  152. on error resume next
  153. Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
  154. if request("save")="" then
  155. Set objCountFile = objFSO.OpenTextFile(Server.MapPath("inc/sms_txt.asp"),1,True)
  156. If Not objCountFile.AtEndOfStream Then fdata = objCountFile.ReadAll
  157. else
  158. fdata=request("fdata")
  159. Set objCountFile=objFSO.CreateTextFile(Server.MapPath("inc/sms_txt.asp"),True)
  160. objCountFile.Write fdata
  161. end if
  162. objCountFile.Close
  163. Set objCountFile=Nothing
  164. Set objFSO = Nothing
  165. if err.number<>0 then
  166. response.write "您的空间不支持FSO,请同您的空间商联系,或者查看相关权限设置<br>"&Err.Description&""
  167. response.end
  168. end if
  169. %> 
  170. <form method=post action="?action=sms">
  171. <table width="95%" border="0" cellspacing="1" cellpadding="3"  align=center class="tableBorder">
  172. <tr> 
  173. <th width="100%" class="tableHeaderText" height=25>注册条款修改
  174. </th>
  175. </tr>
  176. <tr>
  177. <td class="txlrow">
  178. 注意:文件将被保存在你安装目录下的<B>inc/email_txt.asp</B>里,如果您的空间不支持<font color="red">FSO</font>,请直接编辑该文件!<BR>
  179. <B>修改说明</B>:<BR>
  180. ①修改本文件需要一定HTML和ASP代码知识,如果您不会,请不要随意改动<BR>
  181. ②文件中带有《%%》和"&&"之类的字符不要随意做改动<BR>
  182. ③body变量是短信内容变量,txl_info(0)是同学录名称变量,chr(10)是<B>换行</B>符号<BR>
  183. ④<B>不可用回车</B>,增加内容请直接添加或者使用换行符号后添加<BR>
  184. ⑤<B>不可用HTML代码</B>
  185. </td>
  186. </tr>
  187. <tr>
  188. <td class="txlrow">
  189. <textarea name="fdata" cols="100" rows="15"><%=fdata%></textarea>
  190. </td>
  191. </tr>
  192. <tr>
  193. <td class="txlrow">
  194. <input type="reset" name="Reset" value="重新修改">
  195. <input type="submit" name="save" value="提交修改"> 当前文件路径:<b><%=Server.MapPath("inc/sms_txt.asp")%></b>
  196. </td>
  197. </tr>
  198. </form>
  199. </table>
  200. <%
  201. end sub
  202. %>