When using that link as an img src, it triggers an event. I would like to know if I would be able to set the dimension value in this tracking pixel. Thanks for your help in advance
0
votes
This is probably off topic as it's not related to coding, but to add the custom dimension you would add cd<customDimensionSlot>=value to the URL. But how would you achieve this? Using GA sendHitTask or buildHitTask?
- nyuen
It's sort of ghetto, but i'm dynamically creating a url that fills in the parameters in the url in php and sending it off to google which retrieves a 1 x 1 px img.
- user2609670
1 Answers
0
votes
Yes, you can set a custom dimension via the Measurement Protocol (what you're calling the tracking pixel) using the &cd<dimensionIndex>= parameter.
To make sure your Measurement Protocol hits are valid, you can test them using the Measurement Protocol Hit Builder.