Expand my Community achievements bar.

Webinar: Adobe Customer Journey Analytics Product Innovations: A Quarterly Overview. Come learn for the Adobe Analytics Product team who will be covering AJO reporting, Graph-based Stitching, guided analysis for CJA, and more!
SOLVED

How to get the full query string parameter into AA / using Launch

Avatar

Level 1

How can I get the the full query string parameter into AA?

Sure, its part of the page-url, but since they are sometimes are longer than 255 signs, it is cut off in AA.

 

I am using Adobe Launch / Tagmanager. There I only found the WebSDK Plugin where you can use "getQueryParam" as DataElement Source. But there you need to configure every param in advance. But I dont know every param.

 

Example:

Current page url has some parameters:

- https://domain.com?param1=foo&random2=bar&utm_source=search&rss=true 

My expected return string would be the full path without domain.
- ?param1=foo&random2=bar&utm_source=search&rss=true

 

Any idea?

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

I would just use a custom code Data Element:

 

var params = window.location.search;
return params;

 

If there are no parameters, it should return an empty string ("")

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

I would just use a custom code Data Element:

 

var params = window.location.search;
return params;

 

If there are no parameters, it should return an empty string ("")

Avatar

Community Advisor

Note that even with this solution, you are still limited to 255 characters. That is a hard limit of eVars that is built into Adobe Analytics, and you can't overcome that.

If you have a very loooooong query string but really only need to track some queries, then you could modify Jennifer's solution to pick out those specific queries only and track them. Hopefully, the final length is still less than or equal to 255 characters.