Hi
What would be the best method to delay a server call on a specific page?
Regards
Roy
Solved! Go to Solution.
Views
Replies
Total Likes
Ok great this helps. Ajax calls sort of can act like a SPA where the order of data being ready vs callback happening and in essence its a sort of race condition.
See this link here.
https://experienceleague.adobe.com/docs/analytics/implementation/other/ajax.html?lang=en
If this still doesn't work investigate a Direct call rule as well as then leveraging a Digital data layer. That way you could have more control over when header tag is fired, via direct call rule, then give page time enough to set all desired variables and then close off with page bottom snippet to complete the data capture and send.
GLTU
Views
Replies
Total Likes
There are many factors to give you an answer but...
Perhaps a Direct call rule. Can you expand on what is causing you issues? What platform/server environment you are on?
Is it a Single page app type of page?
Views
Replies
Total Likes
Thanks a lot for your reply.
It's not a single page app. It's an ecommerce pages using Ajax and different Web methods calling runtime components. I am using callback function to capture information from the page but I am unable to pass it inside Adobe props, evars and the reason being server call happening well before callback function executes.
Views
Replies
Total Likes
Ok great this helps. Ajax calls sort of can act like a SPA where the order of data being ready vs callback happening and in essence its a sort of race condition.
See this link here.
https://experienceleague.adobe.com/docs/analytics/implementation/other/ajax.html?lang=en
If this still doesn't work investigate a Direct call rule as well as then leveraging a Digital data layer. That way you could have more control over when header tag is fired, via direct call rule, then give page time enough to set all desired variables and then close off with page bottom snippet to complete the data capture and send.
GLTU
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies