Class $sf.pub.PosConfig
| Constructor Attributes | Constructor Name and Description |
|---|---|
|
$sf.pub.PosConfig(posIDorObj, destID, baseConf)
Configure a particualar position for rendering a SafeFrame
Each $sf.pub.PosConfig object has an id property that should be unique.
|
Class Detail
$sf.pub.PosConfig(posIDorObj, destID, baseConf)
Configure a particualar position for rendering a SafeFrame
Each $sf.pub.PosConfig object has an id property that should be unique. Creating a new $sf.pub.PosConfig with an id, that has already been
used results in changing the old $sf.pub.PosConfig settings, and can only be done if the SafeFrames library is not busy.
Automatically ads to the position map of the $sf.pub.Config object if said config has already been created.
- Parameters:
- {Object|String} posIDorObj
- The id of the $sf.pub.PosConfig instance, or an object containing all settings that are to be used for the instance.
- {String} posIDorObj.id Optional
- The id of the $sf.pub.PosConfig instance, if not specified one will be generated automatically.
- {String} posIDorObj.dest Optional
- The HTML element id attribute of the HTML element in the document where a SafeFrame will be rendered. Said element MUST exist within the page prior to a render.
- {String} posIDorObj.bg Optional
- The color of the background to be used inside the SafeFrame. Default equals "transparent".
- {String} posIDorObj.tgt Optional
- The name of the target window where hyperlinks inside a SafeFrame will navigate too...Note that "_self" is not allowed and always converted to "_top". Allowed values are any string value not prefixed with "_", or "_top" or "_blank".
- {String} posIDorObj.css Optional
- A string of CSS rules, or a URL that points to a CSS style sheet to be used inside the SafeFrame
- {Number} posIDorObj.w Optional
- The width of the SafeFrame, specified in pixels. Cannot be specified in em, % or another values.
- {Number} posIDorObj.h Optional
- The height of the SafeFrame, specified in pixels. Cannot be specified in em, % or another values.
- {String} posIDorObj.size Optional
- A string formated as "widthXheight", that defines the width and height of the SafeFrame. The delimiter character "X" is can be specified as lower or upper case.
- {String} posIDorObj.z Optional
- The z-index of the SafeFrame.
- {Object} posIDorObj.supports Optional
- An object containing key/value pairs for what features/actions are supported by the SafeFrame, and its corresponding value represents a boolean detereming whether that feature can be used. Currently supported keys are "exp-ovr" == SafeFrame can expand in overlay mode, "exp-push" == SafeFrame can expand in push mode, and "bg" == SafeFrame can change the background of the publisher / host.
- {String} destID Optional
- The HTML element id attribute of the HTML element in the document where a SafeFrame will be rendered. Said element MUST exist within the page prior to a render.
- {Object} baseConf Optional
- An object representing a $sf.pub.Config object to automatically use / create for the SafeFrames library. Note that baseConf can only be used one time, otherwise you have to use the $sf.pub.Config object directly.