Expand my Community achievements bar.

Help shape the future of AI assistance by participating in this quick card sorting activity. Your input will help create a more effective system that better serves your needs and those of your colleagues.
SOLVED

Dynamic Tag Manager

Avatar

Level 2

I have two doubts to start working  with this tool

How can I populate an evar or a prop whith the value of a Data Element?.As I see in the  page rules edit interface I´m only able to put a fixed string value.

And how can I populate s.products variable? (without coding).

Thanks in advance

1 Accepted Solution

Avatar

Correct answer by
Employee

You can type % into the field where you would like to use the Data Element.  You will see a drop-down list appear with the data elements you've created.  Select the one you want (or keep typing to narrow down the list).  You'll see that the data element is referenced in between percent signs.  Now, when the rule fires, that value will be dynamically populated based on your definition of the Data Element.  

View solution in original post

7 Replies

Avatar

Correct answer by
Employee

You can type % into the field where you would like to use the Data Element.  You will see a drop-down list appear with the data elements you've created.  Select the one you want (or keep typing to narrow down the list).  You'll see that the data element is referenced in between percent signs.  Now, when the rule fires, that value will be dynamically populated based on your definition of the Data Element.  

Avatar

Employee

Also, to use a Data Element in a custom code section, you can use _satellite.getVar('data_element_name')

For example:

s.products = _satellite.getVar('data_element_name');

Avatar

Level 1

Erika Barber wrote...

Also, to use a Data Element in a custom code section, you can use _satellite.getVar('data_element_name')

For example:

s.products = _satellite.getVar('data_element_name');

 

 

This doesn't seem to be working for me with a direct call rule. When I fire a Direct Call Rule, the s object isn't available. Even if I try to access it via window.s it isn't available.

I understand that the s object is available in the custom page code that runs in the tool just prior to sending the page call. But when using an asynchronous call the s object is not available.

How can we set the s.products variable using a Direct Call Rule?

Avatar

Level 1

Was the direct-call rule called from Javascript as the page loads or due to a use interaction?

Avatar

Level 1

One thing that we have discovered is that there seems to be a difference in the availability of the s object if we use appMeasurement versus H.26 s_code.

The workaround has been one of two things:

1. Re-instantiate the appMeasurement object in the Managed Code section, then set the report suite again in the Customize Page Code area of the Adobe Analytics Tool Settings, and put it into an s variable. 

2. Use H.26 instead of appMeasurement

Regardless of how we approach this problem, the s object just isn't available in many places where we might put code. In some instances, we can find the s object by setting s = window.s.

I'm wondering if there is a spot inside the Satellite object where we can put events and variables that need to be put into the s object whenever it is available in case there is a timing or scope problem?

Avatar

Level 1

In this case, it's user interaction.