Adding a page delay to page forward function

Hello reader,

I currently have pages on wix that when visited forward onto my clients webpage.

Code as follows:

This is all working fine, however, the page forward function happens so quickly that Google Analytics is failing to acknowledge a visitor has gone through the page and as such I am missing out on this data. I am trying to integrate a page delay of 1-2 seconds so as to provide Analytics with enough time to acknowledge the visit, however, I am struggling to integrate into the existing code.

Hoping somebody on here can help? Any ideas would be greatly appreciated!

Many thanks
Richard

In order to add a delay, you should use the javascript setTimeout function.
setTimeout(function() {

However, for it to work on your page you would need some event to occur to be able to connect the page code where your timeout function will be written, to the html iframe code, so that data could be passed to and from each other.
https://www.wix.com/corvid/reference/$w.HtmlComponent.html