Expand my Community achievements bar.

Join us for an upcoming in-person Adobe Target Skill Builders event ~~> We're hosting these live learning opportunities to equip you with the knowledge and skills to leverage Target successfully. Learn more to see if we'll be coming to a city near you!
SOLVED

Access / Use targetPageParams() values in Target activity

Avatar

Adobe Champion

Hello - I have a Target beginner's question - I understand how to pass data values into a Target mbox using targetPageParams(), my question is how do I access the values from within my Target Activity to display the dynamic values back to the visitor or use these values otherwise within the activity.

 

This seems to be a rather basic item, but I can't seem to find any examples. Any suggestions are welcome: links to documentation/examples or terminology or search terms are appreciated.

 

Another important item, I'm loading Target via Tealium iQ tag management, not Launch.  I can view my custom targetPageParams values in the Adobe Debugger, but would love a code sample or link to same explaining how to work with these values from within my Activity.

 

Thanks

 

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Hi @ActiveMitchell 

 

Once the parameters are passed in Target calls, they can used in below ways

 

1, You can create an audience using these parameters , for activity qualification or reporting audience.

This can be created from Create audience > 

 

2. These values can be used in experience offers, to be shown  to customers.

If the parameter name is 'favoriteColor' then you can fetch the value of this parameter in your code with ${mbox.favoriteColor}

Here is a document for reference > https://experienceleague.adobe.com/docs/target/using/experiences/offers/passing-profile-attributes-t...

 

 

View solution in original post

3 Replies

Avatar

Correct answer by
Employee Advisor

Hi @ActiveMitchell 

 

Once the parameters are passed in Target calls, they can used in below ways

 

1, You can create an audience using these parameters , for activity qualification or reporting audience.

This can be created from Create audience > 

 

2. These values can be used in experience offers, to be shown  to customers.

If the parameter name is 'favoriteColor' then you can fetch the value of this parameter in your code with ${mbox.favoriteColor}

Here is a document for reference > https://experienceleague.adobe.com/docs/target/using/experiences/offers/passing-profile-attributes-t...

 

 

Avatar

Adobe Champion

Delayed reply, but Thank you @Tanvi_Agarwal_  - the info you provided was most helpful.  I was able to complete my proof of concept in very short order.  

 

Avatar

Level 2

Accessing data passed through targetPageParams() in Target activities is crucial for personalization. To access these values, you typically use the Adobe Target JavaScript library. Here's a brief explanation:

In your Target activity, you can access the data passed through targetPageParams() using JavaScript. Let's say you've passed a parameter named "myParameter" into your activity. You can access it within your activity code like this:

// Access the value passed through targetPageParams
var myValue : targetPageParams.myParameter;

// Now you can use myValue for personalization or other purposes within your activity

Remember to include error handling in your code in case the parameter isn't defined to prevent unexpected issues.

Feel free to explore Adobe's Target documentation or consult Tealium's resources for further guidance on your specific setup.