How to Configure the “Who Sees Ads” Plugin

October 12th, 2008 Posted by Chanya

One of the best plugins I’ve come across lately is called “Ozh’ Who Sees Ads.” This plugin lets you control . . . who sees your ads! I use it with Adsense on one of my niche sites and it works really well.

When I first installed the plugin I found it a bit daunting to configure, so I’m providing what I hope are simple step-by-step instructions:

  1. Download the Who Sees Ads plugin to your hard drive, extract it, and upload it to the /wp-content/plugins directory at your site.

  2. Access the Wordpress dashboard, click on Plugins, and activate the plugin.

  3. Click on Settings and then select the “Who Sees Ads” entry that now appears.

  4. We can now create a New Context (rules that govern when the ads are displayed).  Let’s create a rule that displays our Adsense ads to search engine visitors only.Start by entering a name for a new context.  Let’s call it “SearchEngineVisits”


  5. Scroll down to the “Possible Rules” section.  This section contains lots of pre-defined rules for when your ads will be displayed.  Here are the rules that come with the plugin:

    -If Visitor comes from a search engine, display / don’t display
    -If Visitor is a regular reader, display / don’t display
    -If Post is older than XX days, display / don’t display
    -If Visitor is logged in, display / don’t display
    -If Date is between specified date interval, display / don’t display
    -If Ad has been showed less than XX times, display / don’t display
    -If This visitor has viewed this ad less than XX times, display / don’t display
    -If All previous conditions fail, try another context
    -If Any condition, display / don’t display


  6. Scroll further down the page to the “Active Rules” section.  This is where you’ll place the rules you select.

  7. Scroll back up the page to the “Possible Rules” section.  Since we only want our ads to display to our search engine visitors we’ll select the first rule in the list.Simply click on the “X” at the edge of the rule and drag it into the “Active Rules” section as shown below (click on the graphic to enlarge):




  8. Scroll down to the Ad Code section of the page and paste in your Adsense or affiliate ad code as shown below:

  9. Scroll down to the bottom of the page and click on the “Save Context” button.
  10. We’re now ready to place the Who Sees Ads code on our site.

  11. Scroll to the “Name of Context” field at the top of the page.

  12. Select the “SearchEngineVisits” context.


  13. Copy the code that begins with “<?php” by simply dragging your cursor over the text and copying it to the clipboard.  The highlighted text below is what you need to copy:


  14. We now need to edit two of our site’s files:  index.php and home.php.

  15. From your Wordpress dashboard select Design, and then Theme Editor.

  16. Click on “Main Index Template” (index.php) to open the file.

  17. To get your code to appear ABOVE your posts paste your code under the “contentleft” line as shown below:



  18. Save the file.  Open home.php and paste the text into the same location.  Save the file.Please note, where you place the code will vary according to your template’s design.  You may have to play around with this a bit to get it right.
  19. To test the code, access a search engine like Google and enter your site’s name in the search box. Click on the link to your site.  Your ads should appear (it may take awhile to appear if you just created the ad unit in Adsense).



Once your ads are displaying properly you may want to enable the “Click Safety” option. This options prevents you from mistakenly clicking on one of your own ads (something that Google frowns upon). Simply open the Who Sees Ads configuration page, scroll to the very bottom of the screen to the “Global Options” section and enable the “Click Safety” option.

Hope you find these blog tips helpful. Feel free to ask questions in the Comments section.

If you enjoyed this post, please Click Here to Subscribe to My RSS 4 comments

Sunday, October 12th, 2008 at 2:51 pm and is filed under blog tips. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

RSS feed | Trackback URI

4 Comments »

Comment by Clyde Dennis
2008-10-12 15:13:55

Nice find! Thanks for posting on this new plugin and the extensive tutorial.

Comment by Chanya
2008-10-14 07:32:27

You’re welcome. Thanks for dropping in.

 
 
2008-10-22 11:38:44

[...] How to Configure the “Who Sees Ads” Plugin One of the best plugins I’ve come across lately is called “Ozh’ Who Sees Ads.” This plugin lets you control . . . who sees your ads! I use it with Adsense on one of my niche sites and it works really well. [...]

 
Comment by Blogging Tips
2008-12-18 22:52:10

I love this plugin .. I use it to rotate ads on all my blogs.

 
Name (required)
E-mail (required - never shown publicly)
URI
Your Comment (smaller size | larger size)
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.