< % if Request.ServerVariables("REQUEST_METHOD") = "POST" then iGuestID = Request.Form("txtID") sGuestEmail = Request.Form("txtEmail") if iGuestID < > "" and sGuestEmail < > "" then '在数据库中更新用户记录 strSQL_UnSubs = "UPDATE Guests SET Guests.Mail_List=" & 0 & _ " WHERE Guests.Guest_ID=" & iGuestID & _ " AND Guests.Guest_Email='" & sGuestEmail & "';" Set oConn = Server.CreateObject("ADODB.Connection") oConn.Open strDSNPath oConn.Execute strSQL_UnSubs, iUpdates on error resume next oConn.Close Set oConn = Nothing if err.number < > 0 then sError = ...SQL语句执行失败提示信息, 略... else if iUpdates < > 0 then sError = ...取消订阅成功提示信息,略... else sError = ...不能找到数据库记录提示信息,略... end if 'iUpdates < > 0 end if 'err.number < > 0 else Response.Redirect("homepage.htm") end if 'iGuestID < > "" end if 'REQUEST_METHOD = "POST" %>