So... let's come to a topic i do not seem to fully understand: The function AttributeValue, especially in combination with the cloudpagesurl function.
I will present three scenarios, two are working and one is not working as expected. Both use the CloudPagesUrl function inside an Email to pass variables to the encrypted cloudpages qs parameter. The DataExtension used for sending the email contains colums named "country", "language" and an id which name is "area". We do not have SubscriberAttributes that are named this way, because we handle everything over dataextensions.
Not working scenario, all variables presented in this case are working and contain correct values inside the newsletter.
Inside the e-Mail:
set @href = RedirectTo(CloudPagesURL(404,'param1',@country,'param2',@language ,'area',@area))
Inside the Cloudpage:
set @country = AttributeValue('param1')
set @language = AttributeValue('param2')
set @area = AttributeValue('area')
Output on the cloudpage for debug purposes:
@country is empty (does not display a value)
@language is empty (does not display a value)
@area is filled correctly
Working scenario1:
Inside the e-Mail:
set @href = RedirectTo(CloudPagesURL(404,'country',@country,'language',@language ,'area',@area))
Inside the Cloudpage:
set @country = AttributeValue('country')
set @language = AttributeValue('language')
set @area = AttributeValue('area')
Output for debug purposes on the cloudpage:
@country is filled correctly
@language is filled correctly
@area is filled correctly
Working scenario2:
Inside the e-Mail:
set @href = RedirectTo(CloudPagesURL(404))
Inside the Cloudpage:
set @country = AttributeValue('country')
set @language = AttributeValue('language')
set @area = AttributeValue('area')
Output for debug purposes on the cloudpage:
@country is filled correctly
@language is filled correctly
@area is filled correctly
Now i got several Questions:
- Do the parameters with the AttributeValue function have to be exactly named like the columns in the sending dataextension to be retrieved via AttributeValue when using the CloudpagesUrl function?
- Does the CloudPagesURL function actually encrypts all attributes from the sending dataextension to the qs parameter by default?
- Does the AttributeValue function actually needs the parameter attachments from the CloudPagesURL call? (it seems not)
- Is the AttributeValue function bound to the dataextension column names?
- Does the AttributeValue function still work when the sending dataextensions records get overwritten, updated or deleted?
- Should you better switch to usual parameters to be more failsafe?
- Why does the first (not working) scenario not populate any fields that are not dataextension column names? reference documentation
- Do you actually have to use RequestParameter in this scenario to retrieve the data, because the column names are not matching the sending dataextension and the AttributeValue function will actually not be able to retrieve any data?
Thanks for reading any help is greatly appreciated. If you have more documentation to share please attach it ;)