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

📄 bulletin_update.asp

📁 系统结合实际需求
💻 ASP
字号:
<%@  Language = "VBScript"  %>
<!-- #Include file="..\include\adovbs.inc" -->
<!-- #Include file="..\include\cod_ado.inc" -->
<%
	id = Request.Form("id")
	strTitle  = Request.Form("title")
	strTitle  = replace(strTitle,"'","''")
	strTitle = server.HTMLEncode(strTitle)
	
	strflag_attention = Request.Form("flag_attention")
	if strflag_attention = "on" then
		flag_attention = 1
	else
		flag_attention = 0
	end if
	
	strDetail = Request.Form("detail")
	strDetail = replace(strDetail,"'","''")
		
	'strDetail = server.HTMLEncode(strDetail)
	'strDetail = replace(strDetail,chr(13),"<br>")
	'strDetail = replace(strDetail," ","&nbsp;")
	
	strDetail = replace(strDetail,"<","&lt;")
	strDetail = replace(strDetail,">","&gt;")
	
	set conn = server.CreateObject("adodb.connection")
	conn.Open Application("dsn")
	strSQL = "update board set title = '" & strTitle & "',flag_attention = " & flag_attention &", detail = '" & strDetail & "' where id="&id
    conn.Execute(strSQL)  
	
	conn.Close
	set conn = nothing
	
	response.redirect "bulletin.asp"		
%> 

⌨️ 快捷键说明

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