Creatives
Creative billing

Preview

When entering the page, a user sees the initially collapsed banner. Transition to the expanded banner can be carried out with a click or on the mouse-over. When unfolding, the screenshot of the content “cuts up” into two parts (an “open doors” effect), revealing an expanded banner.

A container with Takeover animation may use only a part of the site content, for example, central, without side columns. In this case, for the container, the necessary dimensions and position are specified, and the animation will only work for the specified part.

Supported platforms

Desktop Tablet Phone
Windows Mac iOS Android iOS Android
Chrome, Firefox Safari9+, Chrome, Firefox

Format requirements

Initial panel

Standard dimensions, WxH, px: 300х250, 240х350, 240х400, 180х150, 320х280, 728х90, 970х90, 970х200, 650х250, 240×500, 300х600, 160х600

Expanded panel

  • Standard dimensions: 100%x100%
  • The layout of the banner should correspond to the size and positioning of the container with the banner in the expanded state (after the Takeover animation was executed). Usually, they correspond to the size and location of the site content on which the banner will be displayed. The background color of the container with the banner should be the same as on the site.

Video

  • Video player container can be of any size within the panel’s borders
  • File type: .mp4
  • Duration: 30 sec
  • Frame rate: 24 fps

Audio

User-initiated (off by default)

Buttons

“X Close” button in the upper right corner of the expanded panel (allows user to collapse the expanded state)

Banner size

  • up to 300 Kb without video
  • up to 2 Mb with video

Download an archive with the template:

Download

  1. Unpack an archive with the creative template.
  2. For creative preview use the preview page. You may also copy all files to folder index – banners – banner- body and open file index.html in browser using localhost.
    In the later case a web server has to be installed (e.g. IIS for Windows, Apache for Mac OS).
  3. Open file body.html with the text editor and edit the code snippet inside tags <body> </body>.
  1. Edit JS files.
  2. Save all banner assets as a ZIP archive (make sure that you zip up files – not the folder).

Assets requirements

ZIP archive

Banner with all banner assets should be archived as a .zip file. It is recommended to use a .zip file with the template.

HTML file

The HTML file must define all used sources (libraries, images, etc). A recommended file name is body.html.

API connection and usage

globalHTML5Api connects automatically, requested using the following method:

Expand the globalHTML5Api code
globalHTML5Api.on('load', function(){
  /*
    YOUR CODE IS HERE
  */
});

All used modules should be listed as function parameters. Two and more modules should be comma-separated. In this format, the Player and Takeover modules may be used.
A simplified example of the globalHTML5Api.init usage for the Takeover format:

Expand the globalHTML5Api.init example code
var takeover = Takeover.create();
globalHTML5Api.init({
	resize: [
		{
			name: "state-1",
			width: "300px",
			height: "250px",
			onComplete: function () {
				//function();
			},
			onStart: function () {
				//function();
			}
		},
		{
			name: "state-2",
			width: "100%",
			height: "100%",
			fixed: {
				vertical: "center",
				horizontal: "center"
			},
			onComplete: function () {
				takeover.show("cut", {
					time: 2,
					degree: 90,
					target: "horizontal",
					onComplete: function (expand) {
						//function();
					},
					onStart: function () {
						//function();
					}
				});
			},
			onStart: function () {
				//function();
			}
		}
	]
});

globalHTML5Api.init parameters

Key Parameters Properties Type Description
resize(options) globalHTML5Api.resize initialization
options Array An array of objects with properties. Each object presents the container state (resizeState)
name (required) String Object (state) name
width (required) String|Number Banner container width
height (required) String|Number Banner container height
fixed Object Object with properties. Describes the container position relatively to the browser window
vertical (required) center String The vertical alignment of the container
horizontal (required) center String The horizontal alignment of the container
onComplete Function Callback function running upon completion of globalHTML5Api.init.resize.to(this.name)
onStart Function Callback function running upon starting of globalHTML5Api.init.resize.to(this.name)

globalHTML5Api.resize methods

Method Parameters Type Description
to(resizeStateName, time, eventName) Changing the current container state to indicated one
resizeStateName (required) String Container state to which the current one should be switched to
time (required) Number Time for the container state-changing animation
eventName  (required) String Events for tracking:

  • adExpand – an ad container is expanding;
  • adCollapse – an ad container is collapsing;
  • adExpandAuto – an ad container is expanding automatically;
  • adCollapseAuto -an ad container is collapsing automatically.
currentState() The method returns the string:
resizeState.name – current container state name
interactive to resizeState.name – changing the container state to the indicated one

A simplified example of using the Takeover module can be found below (click to expand).

Expand the sample Takeover module code
var takeover = Takeover.create();
takeover.container(document.getElementById("container"));
takeover.show("cut", {
	time: 2,
	target: "horizontal",
	degree: 90,
	onComplete: function () {
		//function();
	},
	onStart: function () {
		//function();
	}
});
takeover.on("ready", function(){
	//function();
	takeover.hide(2);
	};
});

Takeover parameters

Method Parameters Properties Type Description
create() Takeover initialization
container(HTMLElement) A method that adds Takeover to the specified container
HTMLElement String HTML element with the Takeover layout
show(“cut”, options) The method starts Takeover animation
cut String Takeover animation type
options Object An object with properties
target (required) horizontal, vertical String Plane in which the screensot “cuts up”
time (required) Number The time for which Takeover animation is performed; sec
degree (required) Number An angle of the screenshot’s turn
onStart (optional) Function Calling the function at the start of the Takeover animation
onComplete (optional) Function Calling the function at the completion of the Takeover animation
hide(timeScale) The method starts the Takeover animation in the opposite direction
timeScale (optional) Number The value acts as a multiplier for time,
accelerates or slows down the animation while minimizing Takeover
on(“ready”, callback) The method allows you to call functions on the readiness of the screenshot of the site content
ready String Event that occurs when a screenshot of the site is available
callback Function The function, which starts when the screenshot of the site is available

globalHTML5Api methods

Method Arguments Type Description
click(URL) Method to call the clickthrough. Target URL may be set as a parameter or from the user interface. The URL set in the code has a higher priority than the URL set from the UI, which can lead to a conflict. Therefore, it is mandatory to use only one of the available methods.
URL (optional) String Target URL
src(URL) Method returns the absolute path to file
URL (optional) String Relative path to file

Video

In case the creative contains video, see the Video player module page.

Images

Supported file types: .jpg, .png, .gif, .svg

Event tracking

  • View
  • Confirmed view
  • Click
  • Expand by user
  • Auto-expand
  • Collapse by user
  • Auto-collapse
  • Play
  • Pause
  • Resume
  • Sound on
  • Sound off
  • Progress (firstQuartile, midpoint, thirdQuartile, complete)

Known issues

  • The format will not work correctly if it was posted on the site in Safe Frame.
  • In the Safari browser version 11 and higher, automatic video playback is not possible with the sound turned on.
For any questions regarding ad manuals please contact the support manager of your account.
Updated on December 18, 2023