<% indexid = Request.Querystring("id") If indexid = "" OR isNumeric(indexid) = false Then call errormsg Response.end Else Set conn = Server.CreateObject("ADODB.Connection") conn.open Application("connstring") sql = "SELECT * From unsubscribes WHERE indexid = " & indexid Set rs = conn.execute(sql) If rs.eof then bError = true Else bError = false firstname = rs("firstname") lastname = rs("lastname") email = rs("email") daysonlist = rs("daysonlist") sitecode = rs("sitecode") source = rs("source") state = rs("state") country = rs("country") 'record the re-subscribe sql = "INSERT into mailinglist (state, country, sitecode, source, firstname, lastname, email, daysonlist) VALUES ('" & _ state & "','" & sqlprep(country) & "','" & sitecode & "','" & source & "','" & sqlprep(firstname) & "','" & sqlprep(lastname) & "','" & email & "'," & daysonlist & ")" conn.execute(sql) 'delete from supression list sql = "DELETE from unsubscribes WHERE indexid = " & indexid conn.execute(sql) End If Set rs = nothing conn.close set conn = nothing If bError = true Then call errormsg Response.end End If End If %>

You have now been re-activated on the Flourish Diabetes Updates mailing list.

Click here to return to our site

<% Sub errormsg %>

There was an error processing your request. We could not find your record in our database.

<% End Sub Function sqlprep(str) 'tack on a space to prevent invalid use of null then trim off with trim command sqlprep = Trim(Replace(str & " ","'","''")) End Function %>