SOLVED

Re: Trying to Track Clicks on a Marketo Landing Page

Go to solution
Derek_Hays1
Level 1

Re: Trying to Track Clicks on a Marketo Landing Page

@SanfordWhiteman Here's a test version of the form/page in question. Lots of videos on this page. But when I scaled it back to just the examples in this string (e.g. your code, and the YouTube API example), the behavior was still the same . The behavior is this: If you complete form, the content (page and videos) load without problem from the WP site. But if you return to the page (Known Visitor), the page loads minus the videos. It is the same code in both places, hence my question does the MKTO Known Visitor page process JavaScript differently? Thanks. 

SanfordWhiteman
Level 10 - Community Moderator

Re: Trying to Track Clicks on a Marketo Landing Page

do see your custom video tracking hits, though, when the videos are in the KV HTML area:

 

2020-05-09 16_18_18-CodePen - SaltStack-MktoForms2 __ YT tracker.png

 

(That's a very aggressive use of KV HTML! Don't think I've ever packed that much HTML into the space, nothing inherently wrong with it but it increases the size of the form descriptor a ton — would be more efficient to have that HTML hidden lazy-loaded somewhere else on the page and then inject it into the KV HTML, so it wouldn't affect load time when the session isn't yet known. But that's off-topic.)

Derek_Hays1
Level 1

Re: Trying to Track Clicks on a Marketo Landing Page

@SanfordWhiteman Thanks for your response. I agree that there's a lot in that page and like your efficiency suggestion. I will look at that. 

Any ideas on why the Known Visitor page would not load the videos though? Even when I scale that page back to just two videos, I can't get them to load. I had this loading process working for 5 months, then the form got updated, the video stopped loading, and I'm at a loss to why. 

SanfordWhiteman
Level 10 - Community Moderator

Re: Trying to Track Clicks on a Marketo Landing Page

I'm saying it does load and track the videos for me.

Derek_Hays1
Level 1

Re: Trying to Track Clicks on a Marketo Landing Page

I'm glad you can see them. But also perplexed. As I cannot.  


I did some more testing. If I take the video loading/tracking javascript out of the WP landing page then the videos load fine in the known visitor page. But I can no longer see them on the form completion page. If I leave the video loading/tracking javascript in the WP landing page then the videos load upon form completion but not when I return to page as a known visitor. 

 

I believe the issue is not with the javascript used for loading and tracking the videos. Instead the conflict seems to be come displaying the videos from both the WordPress landing page (form successfully completed) and from the Known Visitor (Marketo) pages.

 

I believe the issue is related to the "visible/hidden" javascript that hides the landing page content/videos until after the form has been submitted. While this approach does hide the content (including videos) until the form is completed, it still loads the content in the background.

 

So when a returning visitor comes to the landing page, the same content (including video loading/tracking javascript elements) are getting loaded twice once from the WordPress landing page (hidden), and a second time from the MKTO known visitor page (visible). And this somehow causes a conflict that keeps the videos from loading.

This is my best take at the moment. I don't have solution worked out yet. Thanks. 

Anonymous
Not applicable

Re: Trying to Track Clicks on a Marketo Landing Page

@ Sanford, that is sweet, thanks for sharing that!

Yes one benefit of the Vidyard integration is that you see the incremental activities with percentages, so "Watched 50%", "Watched 75%", etc.