Forums

This topic is locked

URL-variables in an email returnig to site by clic

Posted 02 May 2003 21:17:27
1
has voted
02 May 2003 21:17:27 Richard Krawczak posted:
Hi there,

Trying to construct an email that sends some confirmation information regarding an order they placed earlier on my site.

When they click the link in the received email, variables fastened to the URL with an “?”, are send back to the site to a specific file.asp that will process the received variables further one.

I’ve tried to solve this problem by using CDO and making my email HTML compliant giving a Mail and Body Format equals 0 . Then making an “a herf” including the 3 variables with an “&” to link back to that specific asp on my site that will do the processing..
But I can’t seem to make it work. I give the code so you can see what I’ve tried so far.

<%
set rs_email = Server.CreateObject("ADODB.Recordset"
rs_email.ActiveConnection = MM_molk_conn_STRING
rs_email.Source = "SELECT * FROM Klanten WHERE Klant_Id = " + Replace(rs_email__MMColParam, "'", "''" + ""
rs_email.CursorType = 0
rs_email.CursorLocation = 2
rs_email.LockType = 3
rs_email.Open()
rs_email_numRows = 0
%>
<%
Set objMail = CreateObject("CDONTS.NewMail"
objMail.MailFormat = 0
objMail.BodyFormat = 0
objMail.From = " "
objMail.to = rs_email("Email"
objMail.Subject = "Bevestiging bestelling kledingvoordeverpleging.nl"
objMail.Body = "Ordernummer: " & rs_email("Klant_Id" & vbCr & rs_email("Bedrijfsnaam"& vbCr & rs_email("Email" & vbCr & rs_email("Telefoon" & vbCr & rs_email("Fax" & vbCr & rs_email("Adres" & vbCr & rs_email("Postcode" & vbCr & rs_email("Woonplaats" & vbCr & vbCr & "Geachte heer, mevrouw, " & rs_email("Achternaam" & vbCr & vbCr & "Wij hebben uw bestelling in goede orde ontvangen." & vbCr & "Klik op de bevestigingslink om uw order naar ons toe te bevestigen. Zorg daarbij dat uw computer met het internet is verbonden en uw eventuele firewall de verbinding toestaat"&vbCr & "Dan zullen wij uw bestelling zo spoedig mogelijk in behandeling nemen." & vbCr & "De levertijd bedraagt twee weken voor onbedrukte artikelen. U kunt de artikelen kosteloos binnen twee weken ruilen." & vbCr & "Ruilen nadien kan ook. Dan zijn echter wel de verzendkosten voor uw rekening." & "<a href = 'molk.nl/hoofdmap/confirm.asp & "?" & valid = "true" & id = rs_email("Klant_Id" & email= rs_email("Email"'>Klik hier om uw order te bevestigen </a>" & vbCr & vbCr & vbCr & "met vriendelijke groet," & vbCr & vbCr & vbCr & "Molk&Ant."
objMail.Send()
Set objMail = nothing
%>
<html>

If anybody has an answer to this problem or a (better)different solution that can do better, please mail me.


Regards


JJF


Reply to this topic