P2 Header Ad – Version 1.5 released

Screen Shot 2014-09-20 at 11.15.53

I’ve just updated my P2 Header Ad plugin with some new options:

  • you can now display the same ad again after the post content (before the comments)
  • you can do this on single posts, and additionally on the front page if you like

These options are not enabled by default and work best if you have longer posts on your site – the look a bit naff if you use your P2 site mainly for short status updates.

I’ve also spruced up the graphic assets that are used on WordPress.org while I was at it. Check out the new options in the Admin Interface (it’s still under Appearance – P2 Header Ad):

screenshot-2

Note on Google Adsense ads

If you’re using both options above with Google Adsense ads, please note that those can only be shown up to 5 times on a single page. If your front page shows 5 posts or more, then the ad can no longer be displayed in the header (which is called last for performance reasons).

If you want to use the after-content-front-page-ad feature, and you want the header to show first, you can tweak line 293 of the main plugin file (p2-header-ad.php) from this

add_action ('get_footer', 'p2DisplayAdvert');

to

add_action ('get_header', 'p2DisplayAdvert');

I may make this an option in the admin interface in a future update. Let me know if you have any questions. Enjoy the plugin, you can download it from within WordPress, on WordPress.org on GitHub:





You can leave a comment on my original post.