How to set blank order variables when page is reloaded?

Bronze Contributor
Bronze Contributor
Currently, if a user reloads the order confirmation page, the pixel fires again and sends duplicate values to our vendors. Is there a way to set an extension to send blank order values when the page is reloaded?
3 REPLIES 3

How to set blank order variables when page is reloaded?

Gold Contributor
Gold Contributor
Hi Bryan If you're sending an orderID along, then de-duplication is something to be sorted by the tool who's analysing the data than the tool sending the data. However, you could use the persist data value extension to save the order ID in a cookie on every thank you pageLoad and run a rule that checks orderID is not equivalent to this cookie value for respective tags you want to de-duplicate . You can also do the same using a javascript extension and load rule. Cheers Samrat D'souza

How to set blank order variables when page is reloaded?

Employee Emeritus
Samrat's suggestion with the cookie makes sense, except if you have the kind of site that reloads the order-confirmation data layer on all past orders as well. This can be something difficult to work around. Ideally, your development team should be encoding the data layer for purchases to only load on the initial purchase. Subsequent reloads of any kind should suppress the purchasing data layer completely.

How to set blank order variables when page is reloaded?

Bronze Contributor
Bronze Contributor
Thanks for the recommendations Son/Samrat. We had our dev team update that page, so that anytime a user clicks back or reload, it outputs all blank order details (i.e. confirmation number, order total, quantity, etc.). We then setup a rule within the tag, so that it will only fire when the order ID is defined and populated. It seems to be working well, as our vendor has not received double orders since then. Thanks again for your help.
Public