0

im trying to store the date and time when a subscriber hit the confirm button or visit the confirmation cloud page.

Currently I have built 2 Cloud Pages, 1x for Preference Center and 1x for Confirmation Page. After submitting the preference the subscriber filled in, the attributes are updated in the "double opt-in List" correctly but not the date and time.

Ive implemented the ampscript in the preference cloud page, I know I have to implement in the HTML-Email or confirmation cloudpage

Its similar to How to capture Opt-in 'Date/Time' on clicking 'Double Opt-in' confirmation link

Thank you for your advice

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Doi Test</title>
</head>
<body>
<form action="http://cl.exct.net/subscribe.aspx?lid=XXXX" name="subscribeForm" method="post">
<input type="hidden" name="thx" value="www.confirmyouremail.de" />
<input type="hidden" name="err" value="www.Somethingwrong.com" />
<input type="hidden" name="usub" value="www.badnews.de" />
<input type="hidden" name="MID" value="XXXXX" />
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td><font face="Verdana" size="2">First Name:</font></td>
<td><input type="text" name="First Name" /></td>
</tr>
<tr>
<tr>
<td><font face="Verdana" size="2">Last Name:</font></td>
<td><input type="text" name="Last Name" /></td>
</tr>
<tr>
<td><font face="Verdana" size="2">Company Name:</font></td>
<td><input type="text" name="Company" /></td>
</tr>
<tr>
<td><font face="Verdana" size="2">Email:</font></td>
<td><input type="text" name="Email Address" /></td>
</tr>
<tr>
<td><input type="radio" name="Email Type" value="HTML" checked="checked" />
<font face="Verdana" size="2">HTML</font>
</td>
<td><input type="radio" name="Germany Research" value="true" checked="checked" />
<font face="Verdana" size="2">Germany Research</font>
</td>
<input type="hidden" name="Preferred Language" value="German"/>

%%[
Var @DOI_Opt-in_date
SET @DOI_Opt-in_date = FormatDate(NOW())
]%%

<td>
<input type="radio" name="Email Type" value="TEXT" />
<font face="Verdana" size="2"> Text</font>
</td>
</tr>
<tr>
<td>
<input type="radio" name="SubAction" value="sub_add_update" checked="checked" />
<font face="Verdana" size="2">Subscribe</font>
</td>
<td>
<input type="radio" name="SubAction" value="unsub" />
<font face="Verdana" size="2">Unsubscribe</font>
</td>
</tr>
<tr>
<td>
<input type="submit" value="Submit" /></td>
<td align="right">
<font face="verdana" size="1" color="#4C5487">
</font>
</td>
</tr>
</table>                                                                                                                                      
</form>
</body>
</html>

1 Answer 1

0

I see that you are setting @DOI_Opt-in_date but I don't see anything in you code about processing the page.

You should either log your attribute as a field value and then process or ideally on your processing page set the date variable and then pass that into the data extension.

It would be useful to see the Ampscript in your processing page - it might be a case you haven't included the attribute in your data extension upsert.

Another alternative solution is to make the date in the data extension nullable, and set a default value of 'Current Date' in the data extension.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .