-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add multiformat docs: developers, ad ops, example code (#561)
* WIP multiformat docs * Flesh out prerequisites/implementation of dev doc * Add multi-format docs to 'Docs by Format' * Add a quick example of *why* to do this * Outline steps on ad ops page * Clarify multi-format on 'Docs by format' page * Various dev doc fixups * Update JSFiddle, overview bullet points in example * Update multiformat fiddle * Key is now called `hb_format` * s/multi-format/multiformat/ * Use 'appnexus' bidder and Prebid.js v1 * s/multi-format/multiformat/ * Be clear that it's *outstream* video * Use title case * Update multiformat example link * Fill in multiformat ad ops instructions Because these are basically the same as the banner/native instructions, I've filled them in as the "diffs" between our existing, published, vetted instructions. * Add native aspect ratio info to AN adapter docs (#543) * Add native aspect ratios to AppNexus adapter docs Also did some general cleanup and formatting while I was in there. * Update field defs a bit; add OpenRTB native link * Remove OpenRTB note based on feedback * Add banner, video, and native sections * WIP native updates across several pages * Tweak language in AN bidder doc links * Edit down to a single native example; s/Ast//g * Update native example code; s/Ast//g * Show `mediaTypes.native.image.sizes` in examples In addition to updating the basic examples to use sizes for images and icons, we add a section to both the API reference and the 'Show Native Ads' page that lists both ways to define sizes for image-like assets. Since the content is the same, it's in a shared file sourced using the Liquid `include` keyword. * Fix code formatting issue with included file * `adUnit.sizes` is ignored on native ad units * Remove `adUnit.sizes` since banner sizes are used * Remove redundant `adUnit.sizes` from native ad * Use correct syntax for native "image-type" ad * Add multiformat ad unit information (#541) * Add multiformat ad unit information * Update default targeting keys * Update based on review feedback * Change key to hb_format * Add note about including banner media type if supported * update tag samples with multiformat syntax (#528) * update tag samples with multiformat syntax * reverting part of change on show-native-ads.md * s/multiformat/multi-format/g * We don't need an order per demand partner * Remove ambiguous comment on fluid vs. fixed native * Update multi-format language in dev setup intro * Update multi-format description based on feedback * Update 'How it works' based on feedback * Update ad unit language based on feedback * Fix Prebid.org-hosted multiformat example Somehow a native example was erroneously added -- probably as a placeholder. It has been replaced with a slightly modified version [*] of the multi-format example kindly provided by @matthewlane. [*] It was modified to (1) use Prebid.js v1.2 from the CDN and (2) to use the 'appnexus' rather than the old AST adapter * Update JSFiddle in multiformat example To address the following points: 1. Removing mention of the internal dev URL as mentioned by Jacobson 2. Making the code the same as that of prebid.org/examples/multi_format_example.html * Add ad unit creation step with sizing/native info * Clarify line item setup language * Update k-v targeting instructions per feedback - Use slightly different language/notation - Add screenshots * Check in screenshots of multi-format ad ops setup * Update native format language per feedback * Clarify that it's banner and/or outstream * Note bidder-specific line item targeting keys * Update targeting description per feedback * Update native size note, per feedback * Fix mobile size per feedback * Hide multi-format example from site's left nav * Belatedly add link to the 1.0 release announcement * Fix typo * Use Prebid.org-hosted multi-format example (Also, add it to the `/examples` index page.) * s/div-banner-outstream/div-banner-native/g * Add a third example: 'banner-outstream' * Update examples to set `cache.url` to `false` I'm told this is connected somehow to the following issue, but ¯\_(ツ)_/¯ prebid/Prebid.js#1976 * Update placement IDs in Prebid.org-hosted example In order for outstream to work, we need a placement configured to work with VAST 3.0 since that is what the test outstream creative requires. * Update JSFiddle to use updated placement IDs * Get banner/outstream examples working: use 300x250 Also, added a note to the JSFiddle multi-format example page that the Fiddle works sporadically for outstream, so check out the Prebid.org-hosted example (which works closer to 100% of the time) * Fix broken formatting on JSFiddle example page
- Loading branch information
1 parent
95e1db0
commit 9a54080
Showing
11 changed files
with
487 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
--- | ||
layout: page | ||
title: Setting up Prebid Multi-Format in DFP | ||
head_title: Setting up Prebid Multi-Format in DFP | ||
description: Setting up Prebid Multi-Format in DFP | ||
pid: 3 | ||
hide: false | ||
top_nav_section: adops | ||
nav_section: tutorials | ||
--- | ||
|
||
<div class="bs-docs-section" markdown="1"> | ||
|
||
# Setting up Prebid Multi-Format in DFP | ||
{: .no_toc} | ||
|
||
This page shows how to set up your ad server so that you can serve multi-format ads. | ||
|
||
Multi-Format ads allow you to declare multiple media types on a single ad unit. For example, you can set up one ad on the page that could show a banner, native, or outstream video ad, depending on which had the highest bid. | ||
|
||
{: .alert.alert-info :} | ||
For instructions on how to set up multi-format ads from the engineering side, see [Show Multi-Format Ads with Prebid.js]({{site.baseurl}}/dev-docs/show-multi-format-ads.html). | ||
|
||
* TOC | ||
{: toc } | ||
|
||
## Step 1. Add an Ad Unit | ||
|
||
In DFP, [create an ad unit](https://support.google.com/dfp_premium/answer/177203?hl=en). | ||
|
||
Decide what combination of formats will be permitted on the ad unit. This will determine what sizes you allow to serve. The ad unit's sizes must be configured properly to support the combination of formats that will be permitted. | ||
|
||
If your ad unit will support native ads, you may want to create a custom **Prebid Native Format** and at least one **Prebid Native Style**. Examples of each are given in [Setting up Prebid Native in DFP][nativeAdSetup]. | ||
|
||
## Step 2. Add an Order | ||
|
||
In DFP, create a new order. This order will be associated with the multiple line items needed to run multi-format auctions. | ||
|
||
## Step 3. Add Line Items and Creatives for each Media Type | ||
|
||
Multi-format ad units which support native require at least two distinct sets of line items and creatives: | ||
|
||
+ One for [banners and/or outstream video][bannerAdSetup]. Banners and outstream videos will serve into a DFP banner creative. | ||
|
||
+ One for [native][nativeAdSetup]. Native ads will serve into a native creative with native format and styles. | ||
|
||
### Banner/Outstream | ||
|
||
Follow the instructions for creating line items and creatives in [Send all bids to the ad server][bannerAdSetup], with the following changes: | ||
|
||
+ Add key-value targeting for **'hb_format' is ('banner' OR 'video')** | ||
+ This will ensure that the appropriate ad server line item is activated for banner / outstream bids | ||
+ For bidder-specific line items, specify `hb_format_{BIDDER_CODE}`, e.g., `hb_format_appnexus` | ||
|
||
![Set hb_format to 'banner,video']({{site.baseurl}}/assets/images/ad-ops/multi-format/hb_format_video_banner.png) | ||
|
||
+ Make sure that you're targeting the right sizes for both banner ads and any outstream ads you want to serve in this slot, e.g., | ||
+ 1x1 for outstream (or whatever size you pass into DFP as your outstream impression) | ||
+ whatever banner sizes are valid for your site / use case | ||
|
||
### Native | ||
|
||
Follow the instructions for creating line items, creatives, custom native formats, and native styles in [Show Native Ads][nativeAdSetup], with the following changes: | ||
|
||
+ Add key-value targeting for **'hb_format' is 'native'** | ||
|
||
![Set 'hb_format' to 'native']({{site.baseurl}}/assets/images/ad-ops/multi-format/hb_format_native.png) | ||
|
||
+ Make sure you're targeting the right sizes for the native ads you want to serve: | ||
+ Fixed-size native, where you specify one or more absolute sizes | ||
+ Fluid, which expands to fit whatever space it's put in | ||
+ For more information on fluid vs. fixed, see [the DFP docs](https://support.google.com/dfp_premium/answer/6366914?hl=en) | ||
|
||
## Related Topics | ||
|
||
+ [Show Multi-Format Ads with Prebid.js]({{site.baseurl}}/dev-docs/show-multi-format-ads.html) (Engineering setup) | ||
+ [Multi-Format Example]({{site.baseurl}}/dev-docs/examples/multi-format-example.html) (Example code) | ||
|
||
</div> | ||
|
||
<!-- Reference Links --> | ||
|
||
[bannerAdSetup]: {{site.baseurl}}/adops/send-all-bids-adops.html | ||
[nativeAdSetup]: {{site.baseurl}}/adops/setting-up-prebid-native-in-dfp.html | ||
[createCustomNativeFormat]: {{site.baseurl}}/adops/setting-up-prebid-native-in-dfp.html#create-a-custom-native-ad-format |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
layout: example | ||
title: Prebid.js Multi-Format Example | ||
description: Prebid.js Multi-Format Example | ||
top_nav_section: dev_docs | ||
nav_section: quick-start | ||
hide: true | ||
about: | ||
- Multi-Format ads allow you to declare multiple media types on a single ad unit | ||
- Set up one ad unit that could show a banner, native, or outstream video ad | ||
- Any bidder that supports at least one of the listed media types can participate in the auction for that ad unit | ||
- For engineering setup instructions, see <a href="/dev-docs/show-multi-format-ads.html">Show Multi-Format Ads</a> | ||
- For ad ops setup instructions, see <a href="/adops/setting-up-prebid-multi-format-in-dfp.html">Setting up Prebid Multi-Format in DFP</a> | ||
- <em>Note</em> - Outstream ads only work sporadically in the embedded JSFiddle below; try the Prebid.org-hosted <a href="/examples/multi_format_example.html">Multi-Format Example</a> | ||
jsfiddle_link: jsfiddle.net/prebid/mg81j0rw/12/embedded/html,result | ||
code_lines: 110 | ||
code_height: 2389 | ||
use_old_example_style: false | ||
pid: 11 | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.