Skip to content

Commit

Permalink
A lot of branding updates, for #69
Browse files Browse the repository at this point in the history
  • Loading branch information
benlk committed Nov 2, 2018
1 parent fca3764 commit 4132cef
Show file tree
Hide file tree
Showing 12 changed files with 41 additions and 31 deletions.
4 changes: 3 additions & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,16 @@
"authors": [
"nerds@inn.org"
],
"description": "WordPress plugin for serving DFP ads.",
"description": "WordPress plugin for serving Google Ad Manager ads.",
"main": "dfw.php",
"moduleType": [
"es6"
],
"keywords": [
"WordPress",
"DFP",
"DoubleClick",
"Google Ad Manager",
"Google",
"Advertising"
],
Expand Down
13 changes: 8 additions & 5 deletions dfw-init.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ function dfw_add_action() {
class DoubleClick {

/**
* Network code from DFP.
* Network code from GAM.
*
* @var int
*/
Expand Down Expand Up @@ -305,9 +305,9 @@ private function targeting() {
}

/**
* Place a DFP ad.
* Place a Google Ad Manager ad.
*
* @param string $identifier A DFP identifier.
* @param string $identifier A Google Ad Manager ad unit identifier.
* @param string|array $sizes the dimensions the ad could be.
* @param string|array $args additional args.
*/
Expand All @@ -328,7 +328,7 @@ public function place_ad( $identifier, $sizes, $args = null ) {
/**
* Build the ad code.
*
* @param string $identifier A DFP identifier.
* @param string $identifier A Google Ad Manager ad identifier.
* @param string|array $sizes the dimensions the ad could be.
* @param string|array $args additional args.
*/
Expand Down Expand Up @@ -374,10 +374,13 @@ class='$classes'
}


/**
* Store information for a given ad on a page
*/
class DoubleClickAdSlot {

/**
* DFP ad code.
* Google Ad Manager ad code/identifier.
*
* @var String.
*/
Expand Down
10 changes: 5 additions & 5 deletions dfw-options.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
*/
function dfw_plugin_menu() {
add_options_page(
'DoubleClick for WordPress', // $page_title title of the page.
'DoubleClick', // $menu_title the text to be used for the menu.
'Super Cool Ad Manager Plugin', // $page_title title of the page.
'DoubleClick/Ad Manager', // $menu_title the text to be used for the menu.
'manage_options', // $capability required capability for display.
'doubleclick-for-wordpress', // $menu_slug unique slug for menu.
'dfw_option_page_html' // $function callback.
Expand All @@ -28,7 +28,7 @@ function dfw_option_page_html() {
}

echo '<div class="wrap">';
echo '<h2>DoubleClick for WordPress Options</h2>';
echo '<h2>Super Cool Ad ManagerOptions</h2>';
echo '<form method="post" action="options.php">';

settings_fields( 'doubleclick-for-wordpress' );
Expand Down Expand Up @@ -72,7 +72,7 @@ function dfw_register_options() {
// Network Code
add_settings_field(
'dfw_network_code',
'DoubleClick Network Code',
'Google Ad Manager Network Code',
'dfw_network_code_input',
'doubleclick-for-wordpress',
'dfw_network_options'
Expand All @@ -94,7 +94,7 @@ function dfw_register_options() {
add_action( 'admin_init', 'dfw_register_options' );

function dfw_settings_section_intro() {
echo "Enter a DoubleClick for Publisher's Network Code ( <a href='https://developers.google.com/doubleclick-publishers/docs/start#signup' target='_blank'>?</a> )";
echo "Enter a Google Ad Manager Network Code ( <a href='https://developers.google.com/doubleclick-publishers/docs/start#signup' target='_blank'>?</a> )";
}

function dfw_breakpoints_section_intro() {
Expand Down
8 changes: 4 additions & 4 deletions dfw-widget.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* The DoubleClick Ad widget, and related functions
* The Google Ad Manager Ad widget, and related functions
*/

/**
Expand All @@ -14,8 +14,8 @@ class DoubleClick_Widget extends WP_Widget {
public function __construct() {
parent::__construct(
'doubleclick_widget', // Base ID
__( 'DoubleClick Ad', 'dfw' ), // Name
array( 'description' => __( 'Serve ads from DFP.', 'dfw' ) ) // Args.
__( 'Google Ad Manager Ad', 'dfw' ), // Name
array( 'description' => __( 'Serve ads from Google Ad Manager.', 'dfw' ) ) // Args.
);
}

Expand Down Expand Up @@ -51,7 +51,7 @@ public function widget( $args, $instance ) {
} else {
echo sprintf(
'<!-- %1$s %2$s-->',
esc_html__( 'This DoubleClick for WordPress widget is not appearing because the widget has no sizes set for its breakpoints.', 'dfw' ),
esc_html__( 'This Google Ad Manager Ad widget is not appearing because the widget has no sizes set for its breakpoints.', 'dfw' ),
var_export( $instance, true )
);
return;
Expand Down
2 changes: 1 addition & 1 deletion docs/Developer-API.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ $DoubleClick->place_ad('my-identifier',$sizes,$args);

__$identifer__

`String` The DFP identifier for an ad unit (DFP does not require you to create an identifier. If this does not match a value defined in DFP, a network-wide ad will still be requested).
`String` The Google Ad Manager identifier for an ad unit (GAM does not require you to create an identifier. If this does not match a value defined in GAM, a network-wide ad will still be requested).

__$sizes__

Expand Down
8 changes: 4 additions & 4 deletions docs/Targeting.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Targeting

This plugin implements advanced DFP targeting criteria to allow trafficers to specify pages or groups of pages where line items should serve.
This plugin implements advanced Google Ad Manager targeting criteria to allow trafficers to specify pages or groups of pages where line items should serve.

* * *

Expand Down Expand Up @@ -52,15 +52,15 @@ Additional targeting criteria set by the URL of the page.

> eg. target the url [example.com/?**movie=12**](http://example.com/news/) with the targeting string 'p:12'

__Warning__: Targeting strings are limited to 40 characters long by DFP. Targeting URLIs or domains longer than that will result in error.
__Warning__: Targeting strings are limited to 40 characters long by Google Ad Manager. Targeting URLIs or domains longer than that will result in error.

This plugin uses `jQuery.dfp.js`, which provides [a number of other targeting parameters](https://github.com/coop182/jquery.dfp.js#default-url-targeting).

* * *

## 3. Defining targeting criteria in DFP
## 3. Defining targeting criteria in Google Ad Manager

DFP needs to be told what filter keys exist before they can be used.
Google Ad Manager needs to be told what filter keys exist before they can be used.

#### Example

Expand Down
12 changes: 6 additions & 6 deletions docs/readme.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# ![Screenshot](img/dfw.png) DoubleClick for WordPress
# ![Screenshot](img/dfw.png) Super Cool Ad Manager Plugin

Serve DoubleClick ads natively in WordPress. Built to make serving responsive ads easy.
Serve Google Ad Manager ads natively in WordPress. Built to make serving responsive ads easy.

Built by the [Institute for Nonprofit News](http://inn.org/), DoubleClick for WordPress works with [Project Largo](http://largoproject.org/) or any standalone WordPress blog.
Built by the [Institute for Nonprofit News](http://inn.org/), Super Cool Ad Manager Plugin works with [Project Largo](http://largoproject.org/) or any standalone WordPress blog.

* * *

## 1. What is this thing?

This WordPress plugin serves inventory from a DoubleClick for Publisher account on a WordPress site.
This WordPress plugin serves inventory from a Google Ad Manager account on a WordPress site.

No need to copy and paste ad codes or header tags — the plugin generates all of this on its own.

Expand All @@ -20,7 +20,7 @@ For the most basic integration, only two steps are necessary.

#### __2.1. Define Settings__

Under _Settings > DoubleClick for WordPress_ update the field with your network code from DFP, and a place to define breakpoints to serve ads to.
Under **Settings > DoubleClick/Ad Manager** update the field with your network code from Google Ad Manager, and a place to define breakpoints to serve ads to.

**NOTE:** Both Network Code and Breakpoints may be defined by a developer within the WordPress theme. If a developer already defined these values within the theme, a user will know based on their display in the plugin Settings page.

Expand All @@ -34,7 +34,7 @@ Advertisements are placed in two ways.

![Screenshot](img/widget.png)

* The __identifier__ field is the name of a line item in DoubleClick for Publishers. If an line item with the same identifier in DoubleClick matches the identifier set in the widget, the ad will load (subject to conditional targeting set in DFP admin). If the identifier is blank or doesn't match a line item in DFP, the plugin attempts to load inventory from anywhere in the DFP account.
* The __identifier__ field is the name of a line item in Google Ad Manager. If an line item with the same identifier in Google Ad Manager matches the identifier set in the widget, the ad will load (subject to conditional targeting set in Google Ad Manager admin). If the identifier is blank or doesn't match a line item in Google Ad Manager, the plugin attempts to load inventory from anywhere in the Google Ad Manager account.

* Based on breakpoints defined in plugin settings or theme, an __Inventory Size__ can be defined for each breakpoint set either in the plugin settings or via theme function.
* For an ad the same __Inventory Size__ at every breakpoint, use that size in each breakpoint (i.e. `300x250`).
Expand Down
2 changes: 1 addition & 1 deletion inc/block.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Functions related to the DFW plugin's blocks.
* Functions related to the SCAMP plugin's blocks.
*
* @link https://github.com/INN/doubleclick-for-wp/issues/70
*/
Expand Down
6 changes: 4 additions & 2 deletions js/jquery.dfw.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/**
* A few lines of javascript to help the DoubleClick for WordPress plugin.
* Extends jquery.dfw.min.js with some event listeners specific to us.
* A few lines of javascript to help the Google Ad Manager for WordPress plugin
* Extends jquery.dfw.min.js with some event listeners specific to us:
*
* - lazyload
*/
(function() {
var $ = jQuery;
Expand Down
2 changes: 1 addition & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
site_name: DoubleClick for WordPress
site_name: Super Cool Ad Manager Plugin
theme: readthedocs
4 changes: 3 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# DoubleClick for WordPress
# Super Cool Ad Manager Plugin

Serve DoubleClick ads natively in WordPress. Built to make serving responsive ads easy.

[Read the documentation on GitHub](https://github.com/INN/DoubleClick-for-WordPress/tree/master/docs).

This plugin was named "DoubleClick for WordPress" [until](https://github.com/inn/doubleclick-for-wp/issues/69) Google [renamed DoubleClick for Publishers to Google Ad Manager](https://www.blog.google/products/admanager/introducing-google-ad-manager/).
1 change: 1 addition & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ For more advanced documentation for developers and advanced users see [the offic

= 0.3 =

- Rebrands from "DoubleClick for WordPress" to "Super Cool Ad Manager Plugin", because [Google merged DoubleClick for Publishers into Google Ad Manager](https://www.blog.google/products/admanager/introducing-google-ad-manager/).
- Updates to `jquery.dfp.js` version 2.4.2, adding `setCentering` support. [PR #67](https://github.com/INN/doubleclick-for-wp/pull/67) for [issue #66](https://github.com/INN/doubleclick-for-wp/issues/66)
- Removes 'single' page targeting from post-type archives and from static front pages. [PR #72](https://github.com/INN/doubleclick-for-wp/pull/72) for [issue #61](https://github.com/INN/doubleclick-for-wp/issues/61), thanks to GitHub user [dbeniaminov](https://github.com/dbeniaminov).
- Adds "Category" targeting on category archive. [PR #72](https://github.com/INN/doubleclick-for-wp/pull/72) for [issue #61](https://github.com/INN/doubleclick-for-wp/issues/61).
Expand Down

0 comments on commit 4132cef

Please sign in to comment.