Chapter 6. How-to Guides

Insert Ads in Blog Listings

The In-Feed Injector places an In-feed ad between the articles of your category blogs, styled by AdSense to look like the articles around it.

  1. In AdSense, create an In-feed ads ad unit. Let AdSense style it to match your blog, then look at the code it gives you and copy two values: the data-ad-slot number, and the data-ad-layout-key value, which looks like -fb+5w+4e-db+86.

  2. Create a new CLS Ad Slot module. On the Slot Configuration tab, set Ad Unit Type to In-feed Ad unit, and enter the Ad Slot ID and the Ad Layout Key.

  3. On the Layout tab, set the minimum heights to roughly the height of one article in your blog at each screen size.

  4. On the Module tab, type clsadslot-in-feed into Position and press Enter.

  5. On the Menu Assignment tab, choose your category blog pages. Then click Save & Close.

  6. Enable the System - CLS Ad In-Feed Injector plugin, using the link in the Status panel's warning; see the section called “Read the Status Panel”.

  7. To change how often an ad appears, open the plugin and set Feed item intervals. The default, 3, places an ad after every third article.

No ad is placed after the last article on a page, so an ad never sits alone above your pagination.

Tip

As with In-article ads, you can publish several In-feed modules in the position to show different ads in turn.

Note

The In-Feed Injector works on category pages that use the Category Blog layout.