Expand my Community achievements bar.

SOLVED

How to efficiently set page attribute information on the datalayer

Avatar

Level 2

I would like to add attribute information to each page of our website.
Adobe Analytics has a classification function, but considering the linkage to CDP and other tools , we would prefer to place the information in the datalayer.

 

Example
URL: https://XXXX Attribute: for accountants, blog page,...
URL: https://YYYY Attributes: for marketing, Product Page,...


However, we manage thousands of pages, and it is difficult to specify rules by URL in a batch.
How can we efficiently assign attribute information in such cases?
Currently, I am considering either of the following two options, but neither is efficient.

 

-Directly assign attribute information to each page as tags and store them directly from HTML to the datalayer.
-Mapping URLs and attribute information in a spreadsheet using URLs as keys, and outputting the mapping information in json format and storing it in the datalayer via a tag manager.

 

Thanks in advance.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Usually, pushing the attribute into the data layer is the effective way to do it. Your Content Management System (CMS) should allow authors or other authorised roles to set the category for each piece of content. With that, your developers should then be able to read the content category from the CMS and expose that in the data layer for you.

I would say that it's unreliable and ineffective to set the content category in any other way, e.g by the URL, because you'd have to maintain the URL-to-category mapping and have to constantly keep updated on new URLs/pages. And really, content categorisation should be the work of the content owners, not the marketing analyst.

View solution in original post

3 Replies

Avatar

Community Advisor

I assume that you and your content manager have categorised your content already. If you don't have this categorisation yet, then that should be your first step.

With this categorisation, you could then work with your developers to set this in your data layer. You can then pick this up from your tag manager and track it to AA.

Avatar

Level 2

Thank you very much.


We have the content categorized, but we have a huge number of pages and would like to be flexible if the categorization rules change.
It is difficult to push tags to DataLayer one page at a time, so I would like to know if there is an effective way to do this.

Avatar

Correct answer by
Community Advisor

Usually, pushing the attribute into the data layer is the effective way to do it. Your Content Management System (CMS) should allow authors or other authorised roles to set the category for each piece of content. With that, your developers should then be able to read the content category from the CMS and expose that in the data layer for you.

I would say that it's unreliable and ineffective to set the content category in any other way, e.g by the URL, because you'd have to maintain the URL-to-category mapping and have to constantly keep updated on new URLs/pages. And really, content categorisation should be the work of the content owners, not the marketing analyst.