Lets say we have some creative with lots of .js, styles, CSS3 animations and some HTML5 video tags/sources. All this plus tracking as well. Phew!
It's a lot of code, so how do we go about getting that code onto a safeframe layer - most publishers only allow for a single layer to be open at any one time?
Getting content onto a layer involves using a config object - sfAPI.lyr.open(myLayerConf).
That kind of set-up doesn't lend itself to complex content.
What's the best approach for this scenario - iframe in the complex content and use postMessage for comms?
Last edit: kdowd 2015-06-01
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
Lets say we have some creative with lots of .js, styles, CSS3 animations and some HTML5 video tags/sources. All this plus tracking as well. Phew!
It's a lot of code, so how do we go about getting that code onto a safeframe layer - most publishers only allow for a single layer to be open at any one time?
Getting content onto a layer involves using a config object - sfAPI.lyr.open(myLayerConf).
That kind of set-up doesn't lend itself to complex content.
What's the best approach for this scenario - iframe in the complex content and use postMessage for comms?
Last edit: kdowd 2015-06-01
Maybe I can answer my own question - seems like div.innerText could be the way to go...
The downside to this is that assets/.js inside a hidden div (display:none;) still download/execute on initial page load.
Last edit: kdowd 2015-06-02