?? addnew.asp
字號:
<!--#include file="connection.asp"-->
<%
if session("userid") = "" then
Response.Redirect "login.htm"
end if
%>
<%
dim xtitle_name
xtitle_name = request("title_name")
if instr(1,xtitle_name,"'") > 0 then
xtitle_name = replace(xtitle_name,"'","''")
end if
conn.open = connstring
set rs = Server.CreateObject("adodb.recordset")
rs.open "Select title_id from titles order by title_id desc",conn
xmax = 1
if not rs.EOF then
xmax = rs.Fields("title_id") + 1
end if
set rs1 = Server.CreateObject("adodb.recordset")
rs1.open "insert into titles values(" & xmax & ",'" & xtitle_name & "',1)",conn
Response.Redirect "main.asp?flag=added"
%>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -