Query parameters are dropped on redirect

Permalink
We have a client who wants to switch from using cookies to using query parameters for tracking site visitors from ad campaigns. For it to work, the parameters must be maintained in the page URLs as a visitor navigates their site.

For example, a user might enter the site at example.com/landing-page?source=mad-campaign, then use the nav on that page to switch to the products page, at which point the URL should be example.com/products?source=mad-campaign.

I've added some JavaScript that tacks the parameters onto any links on a page. That works, but whenever a C5-based redirect is encountered, the query parameters are dropped. So, for example, if the link in the landing page mentioned above was to an alternate page path for /products, say example.com/new-products-page, then the ?source=mad-campaign is dropped and the user ends up at example.com/products without the query parameters.

Alternate page path is just one of at least three types of redirects in their CMS. I think some may be custom add-ons.

I was hoping to fix it by setting a config parameter, but I don't see anything that easy. Any suggestions?

 
Gondwana replied on at Permalink Reply
Gondwana
I suspect that using php session variables may involve less fighting of the system. They'd be more secure, too.
jonhill replied on at Permalink Reply
In fact, the site in question previously used cookies to track visitors who entered the site via marketing campaigns. That was working fine, but the company was acquired by another that was using different tracking software. They tell me the new tracking software requires that query parameters be used for tracking.

It would be possible to record query parameters in session variables when a user first enters the site from a marketing campaign. I suppose it might be possible too to pass along that info to the tracking software somehow when the user converts by filling out a request form, but it would make everyone much happier if we could just prevent the CMS from discarding the query parameters when there's a redirect.