Attaching the same set of variables with every request

Rookie Contributor

Hello,

In our current setup, some variables e.g. "site_language" or "app_name" are being sent every time even though they do not change.
 
Is there a way to send those variables just once or just when they are edited and tell Tealium to store them and attach them to every data that we sent?
3 REPLIES 3

Attaching the same set of variables with every request

Tealium Expert
Tealium Expert

If you are referring to the populateion of the utag_data object, then the answer is a yes but no. 

On every page load, the tealium utag.js script is re-loaded. The properties exposed in utag_data, cannot be persisted via Tealium TiQ (which runs client side). 

Now, the 'yes' comes in the form of, you can persist data across page loads using standard methods, such as cookies or browser storage. 

However this is not normally recommeded and caution should be taken in determining if this is a solution in your use case. 

If you do persist the the values via cookies or storage, note that a client side script (via TiQ) will need to be used (at least for storage certainly) ito pick up the values and pass them to utag.data

hope that helps

 

Gavin

 

Research your Experience | Improve and Evolve | Leave no one behind
- Don't forget to mark a solution as accepted if it hits the mark -

Attaching the same set of variables with every request

Rookie Contributor

Since ours is a single page application, persisting data on utag.data can be a good solution, thanks.

Attaching the same set of variables with every request

Tealium Expert
Tealium Expert

Hi, ah, that is clearer now.

 

What you may find useful is soem of these functions, in particualr the merge function

kr

 

 

Research your Experience | Improve and Evolve | Leave no one behind
- Don't forget to mark a solution as accepted if it hits the mark -