Expand my Community achievements bar.

SOLVED

Custom Parameters

Avatar

Level 2

Hi,

I have a question. I am using Target Standard to create A/B test. In this test I need to pass a value from the page into Target – Once the page loads I need to get the value from a cookie and pass it to Target. I will then need to use this value to create audience segments so that I can segment audience for the test based on the value stored in the cookie.

 

I am able to get the value from the cookie and so my question is - can I pass this value into Target? If so could you please enlighten me as to how it is done?

 

Thanks & Regards,

Manna.

1 Accepted Solution

Avatar

Correct answer by
Level 10

HI Manna,

If you are trying to send this along with the target-global-mbox call, then you can read the cookie inside targetPageParams function and return the value from the function to send as an mbox parameter in target-global-mbox. Since this is a change on the website page, It would be easy to do if you use any Tag management system like DTM.

More info on targetPageParams can be found here: https://marketing.adobe.com/resources/help/en_US/target/ov/c_pass_parameters_to_global_mbox.html

If you wish to send the value after a user has entered a campaign, then inside the offer code, you can fire a custom mbox using mboxDefine/mboxUpdate with the cookie value as a parameter and then create an audience based on that.

Hope this helps.

View solution in original post

3 Replies

Avatar

Level 10

Hi Manna,

Thanks for submitting your question. 

As per my knowledge this is possible but requires some custom code. Please allow me some time to find out the right answer for you.

Thanks!

Avatar

Correct answer by
Level 10

HI Manna,

If you are trying to send this along with the target-global-mbox call, then you can read the cookie inside targetPageParams function and return the value from the function to send as an mbox parameter in target-global-mbox. Since this is a change on the website page, It would be easy to do if you use any Tag management system like DTM.

More info on targetPageParams can be found here: https://marketing.adobe.com/resources/help/en_US/target/ov/c_pass_parameters_to_global_mbox.html

If you wish to send the value after a user has entered a campaign, then inside the offer code, you can fire a custom mbox using mboxDefine/mboxUpdate with the cookie value as a parameter and then create an audience based on that.

Hope this helps.

Avatar

Level 1

Hi Shekhar, may I know how can we achieve this. I am using targetPageParams  function to pass parameters but if I read it correctly this has to pass before the target call. In my case I want to pass datalayer values/site catalyst values to target-global-mbox but those are updated after DOM ready.

Thanks

Pankaj