0

I would like to use javascript to grab a URL parameter, in this case the "fbclid" parameter from a facebook ad link click.

I want to rename that parameter, so I can properly import it into my CRM and store it. My CRM can only do this with a specific type of parameter name.

So for example, if the URL was:

mysite.com/?fbclid=123456

I would like to turn that into:

mysite.com/?cf_1=123456

And fyi the value of 123456 is autogenerated during the link click, it's not a static number. Sorry if that's obvious, I'm new to this and wanted to be crystal clear.

  • Does this answer your question? [How can I add or update a query string parameter?](https://stackoverflow.com/questions/5999118/how-can-i-add-or-update-a-query-string-parameter) – Konrad Feb 05 '23 at 21:46
  • See this answer in particular https://stackoverflow.com/a/41542008/5089567 – Konrad Feb 05 '23 at 21:47

0 Answers0