1

Scenario : Created one cloudpage with smart capture, using cloudpage URL as CTA in email passing email, FN LN as parameters in CloudpagesURL function.

Email works fine in test and preview but URL breaks when email is sent.

I have this on email

    %%[ 
var @email, @givenName, @familyName 
set @email = [email] 
set @givenName = [givenName] 
set @familyName = [familyName] 
]%% 

This on CTA URL

%%=CloudPagesURL(1509,"email",@email,"givenName",@givenName,"familyName",@familyName)=%%

when previewing the email it works fine but when deploying the email it throws an error

An error has occurred and has been logged by our system. Thank you.

Also, noticed that the cloudpage URL is not generating. Instead of populating the cloudpage URL which is

http://click.info.connect.en/formpage //Dummy
which shows exactly same when email being previewed

the email shows CTA shows below on deployment. UTMs are not bothering but the URL is breaking and I can't get it through.

http://click.info.connect.en/utm_source=sfmc&utm_medium=email&utm_campaign=

along with the error code mentioned above

Cloudpage code:

    %%[ 

var @email, @givenName, @familyName 
set @email = RequestParameter('email') 
set @givenName = RequestParameter('givenName') 
set @familyName = RequestParameter('familyName') 

]%%

Further using smart capture fields to populate values captured using below

value="%%=v(@familyName)=%%

7
  • Sorry, but to clarify, is it the page or the email that is erroring? Commented Jan 27, 2020 at 14:02
  • 1
    Isn't the first thing to do that CloudPagesURL should be wrapped with the RedirectTo-function? (And btw: Looks like you have WAC [web analytics connector] enabled, thats where your link parameters come from) Commented Jan 27, 2020 at 14:21
  • Sorry if i was not clear Gortonington.. I have created a landing page with a form and passing email first name last name from email, so that receiver just have to confirm their details. landing page works fine when saved and published. it also works fine when I test and preview it, all the details are being populated but as soon as I send it the cloud page URL within EMail somehow breaks and shows above error. let me know if this clarifies my situation a bit more. Commented Jan 27, 2020 at 16:09
  • It sounds like there is a problem between the Email's CloudPageURL() link and how your Cloud Page is interpreting the payload of data. Can you update your question with the relevant AMPScript from your Cloud Page that handles the incoming data from the CloudPageURL() function; the email/firstname/surname parts. Commented Jan 28, 2020 at 10:35
  • Hi Cameron, sure it's updated now.. Commented Jan 28, 2020 at 12:07

2 Answers 2

2

We just got an answer from Salesforce support on this... The answer is on this page, though not particularly well delineated. https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-programmatic-content.meta/mc-programmatic-content/cloudpagesurl.htm

The CloudsPagesURL Call has to be wrapped in a RedirectTo

<p><a title="MyPage" href="%%=RedirectTo(CloudPagesURL(77777))=%%" alias="ThisAlias" conversion="false">Click to unsubscribe</a></p>

MicrositeURL did not require this, and there is no explanation of the change. https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-programmatic-content.meta/mc-programmatic-content/MicrositeURL.htm?search_text=micrositeurl

0

I always forget to wrap my links in %%=REDIRECTTO(@LINKVAR)=%%. That should fix most issues for people. If you have parameters use URLENCODE() as well.

You must log in to answer this question.

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