Expand my Community achievements bar.

Join Cristinel Anastasoaie, Timothy Furlow, and Brent Kostak, WEDNESDAY, 2/28/24 @8am PT for the next Adobe Target Community Q&A Coffee Break on topics from the recent High Performance Recommendations Webinar PT 2 of the ongoing Target Personalization Maturity Webinar Series

profile attribute creation and reading profile attribute in profile script


Adobe Champion


I am new to adobe target, trying to write a profile script for a use case.

The use case is like, if user searches by ticked a check box then promote an offer related to the ticked checkbox.

For this i am trying to set a profile attribute when some ticked the checkbox and create a profile script by reade this profile attribute.

Create an audience using this profile script and target an offer.

I didn't fine anywhere how to set a profile attribute in my html page and how to read the attribute value in profile script.

Any help will be much appreciated.

5 Replies




for this use case : 'if user searches by ticked a check box then promote an offer related to the ticked checkbox."

Step 1.  First identify the tick event and in the eventlistener function like click, fire a Dynamic mBox with value relevant to checkbox (which makes sense to you)

(Then ensure dynamic mBox is firing properly on page. This can be checked in Network tab in developer's tool )

Step 2. Then create a profile script and check for the set value of dynamic mBox here and return true when value is what you have set for the checkbox click event.

Step 3. Then Create an audience and use the above profile script where you are validating the dynamic mBox value which you are firing on click of checkbox with the necessary parameters.

Step 4. Use this audience in Target activity.

Hope this helps :-)


Adobe Champion

@skandg thanks for your suggestion.

I tried to create a dynamic mbox as advised by you and the mbox is not triggering

var test="";

if ($('#my_id').is(':checked')) {

test= "B";



mboxUpdate('my_dynamic_mbox, 'test=B’);





mbox is to be defined around a DIV element. You may refer below document to create a dynamic mbox

Creating a Dynamic Mbox

Also below document can be referred for functions being used with at.js

at.js Functions


Employee Advisor

Rather than using mboxDefine/mboxUpdate I'd recommend you use the adobe.target.trackEvent function (only works for at.js). Tanvi linked to a help doc with some details on it. Here is a simple sample though:

You can pass the parameter as a "profile.param1" if you want it to be sticky for the visitor. However, in your use case where you have a profile script looking for attribute you probably don't need to use the "profile." because the profile scripts are sticky too.



As I mentioned before, inside your click event function write code as per below sample:

btn_Click_function(){ // this is your button click function

//Place below code


"mbox": "Checkbox", //define the mBox name here,

"params": {

"profile.checkBoxTicked":true //set the parameter as profile and assign value as 'true'




Hope this helps !