From September, Flash will no longer be supported by Chrome. Prepare for the shift towards HTML5 by visiting our Flash to HTML5 help page

Check it out!

Preload and States

Even if HTML asset is not visible, it will be preloaded in the background after page load. This will help to avoid blinking on for example expand action in double file expanding banner.

Restart animation is no longer supported in HTML asset, so user should add, stop or remove unwished content depending of asset state by himself. HTML asset has 3 states: initial, visible and hidden. User can get current state using dhtml.getState() or listen for state change events through dhtml.sharedEvents.

Example:

var state = dhtml.getState();

console.log('The current state is: ' + state);

dhtml.sharedEvents.on('changed:state', function (s) {
    console.log('Last state was: ' + state);
    console.log('State has changed to: ' + s);
    state = s;
});