Exit on a new page starts animation on page1

25 views
Skip to first unread message

Lasse Salling

unread,
Sep 26, 2017, 9:40:47 AM9/26/17
to Google Web Designer beta
After hunting down a solution to the issue regarding Safari on iOS to ignore the timeline.pause function, I settled with a solution/workaround of going to a new page, rather than pausing the timeline on page1.

Problem kinda solved. What happens now is that when it turns to page2 after the ad has looped twice and I click the banner on a completely new tap area, the animation starts playing on page1 in the banner, then page2 fades ind again over page1.

How would I go about stopping this behaviour, so it just stays on page2 and doesn't restart animation on page1? I just need to freeze what's visible on page2.

Banner can be seen here: http://pixelpirate.dk/temp/dhb2/


Regards,
Lasse

San Khong

unread,
Sep 26, 2017, 1:54:42 PM9/26/17
to gwd...@googlegroups.com
Hi Lasse,

When you exit, the ad automatically goes back to the primary page (or the default page). So what you need to do is to change the default page to page2 before exit.

Switch to code view, find the code gwd.auto_Gwd_taparea_1Action = function(event) {
Below the // GWD Predefined Function, add the following code, make sure it matches your page ID

document.getElementById('pagedeck').getDefaultPage().removeAttribute('default-page');
document.getElementById('pagedeck').setAttribute('default-page', 'page2');

Your taparea exit code should be below that. 
In my example below, my second page has the page id page1_1.



In the next release, you will be able to specify the page id for the ad to go to after exit in the Events dialog when you add the exit event for the Taparea.

Thanks,
San
Google Web Designer team

Lasse Salling

unread,
Sep 27, 2017, 6:29:30 AM9/27/17
to Google Web Designer beta
Hey San

I found another fix just by messing around. On the second exit on page2 I simply unchecked "Collapse on exit" and "Pause media on exit", somehow that stops the banner on page2 on click and tap. Maybe it does kind of the same as your solution. Either way it behaves as it should now. :)


Thanks

Lasse


San Khong

unread,
Sep 27, 2017, 12:30:14 PM9/27/17
to Google Web Designer beta
Thanks for letting me know. 
Reply all
Reply to author
Forward
0 new messages