Loading...

The Drupal DFP module is a useful package that empowers Drupal site builders to easily integrate their DoubleClick for Publishers account and their active advertisements onto a Drupal website. The module is largely plug-and-play, which means that a development background is not necessary to get DFP integrated into a Drupal site. Simply download the module, add it to your website, and start configuring the available options.

After installing and enabling the DFP module, connecting it to your DFP account is as simple as entering your Network Code into the DFP module’s Global Settings page…

  • Your DFP Network Code can be found under the Admin tab of DFP.
  • Prepend your Network Code with a `/` character before entering it into the Global DFP Settings page’s Network ID field.
  • Several other options are available to site builders on the Global DFP Settings page including checkboxes to render advertisements asynchronously, enable DFP’s Ad Categories, and collapse empty advertisement regions.

Once the global settings have been configured you are ready to build and place Drupal DFP blocks!

From the module’s list page site builders can define Drupal blocks to house DFP advertisements…

  • This is done with the “+ Add” button that prints atop the list page. Clicking this opens a new Ad Tag form where site builders can build Drupal blocks that can be placed into any region of the website.
  • After defining an Ad Slot Name and the Ad Size(s), an Ad Unit Pattern must be defined. The value entered here should match the advertisement’s Ad Unit Code, which can be found within DFP after expanding an Ad Unit.
  • Once these three values have been entered, the next step is to access the “Display Options” tab and ensure the checkbox to create a block for this Ad Tag is selected.

These are the only four DFP module configurations necessary to get advertisements to display, although numerous other Ad Tag settings are available to be configured as desired. The DFP module handles the required scripts and elements necessary to render DFP advertisements.

  • Once your Ad Tag has been saved, access the block administration screen and find the DFP block (the block name will be the value entered into the Ad Slot Name field).
  • Assign this DFP block to a region using the block administrative screen and save your changes.
  • Load your website and see that your advertisement is now printing in the region its block was assigned to.

If you encounter a block that is not rendering the expected advertisement, Google has a new feature that may be able to help determine the problem…

  • From the Delivery tab of your DFP account click the “Troubleshoot” link that appears at the bottom of the left-hand sidebar. This will return you to a page where a URL can be entered for troubleshooting.
  • Enter your Drupal website’s address into this field.
  • Click “Troubleshoot” to load the URL in a new browser tab with a DFP overlay that can be used to troubleshoot the block in question.
  • By using the overlay’s Ad Slots tab, find the advertisement that is not rendering as expected and click the “Delivery Diagnostics” link below it for useful information to assist in troubleshooting.

The Drupal DFP module is the perfect bridge to integrate your DoubleClick for Publishers advertisements to your Drupal website. Using this module allows both your advertisement team and website administrator(s) to manage their pieces of the puzzle autonomously.