What Would Seth Godin Do with AdBlock

Seth Godin is a marketing genius. His writing style is unimitable. Ultimately everything boils down to excellent copywriting.  He once remarked about using the power of cookies to greet the returning visitors. This resulted in the making of a WWSGD wordpress plugin.

Taking cues from What Would Seth Godin Do and a WebTemp script, I have created a modified script to detect AdBlock and then show an WWSGD type RSS subscription message.

You may not be monetizing, still increasing feed count should make you happy!

Let someone know me the success with Adbrite/Bidvertiser scripts as inner HTML ;)

Code:

  1. Have your adsense script inside a <DIV id=”adsense”> tag.
  2. Paste the following script just above the </body> tag. In my case it was in the footer.php file.

<script type=”text/javascript”>
setTimeout(’check_ads()’, 1000);
function check_ads() {
var blocked = false;
var e = document.getElementsByTagName(”iframe”);
for (var i = 0; i < e.length; i++)
if ((e[i].src.indexOf(”googlesyndication.com”) > -1) &&
(e[i].setAttribute && (e[i].style.visibility == “hidden” ||
e[i].style.display == “none”))) blocked = true;
if (!window.opera && (!window.google_last_modified_time ||
!google_last_modified_time)) blocked = true;
if ((e.length == 0) || blocked) {
var s = “<p style=’border:thin dotted black; padding:3mm;’>Subscribe to my <a href=’http://vinodlive.com/feed/’>RSS feed</a>. Thanks for visiting!</p>”
document.getElementById(”adsense”).innerHTML = s;
}
}
</script>

Don’t forget to change the feed address to yours.

Readers who viewed this page, also viewed:

Related Posts

Leave a Reply

For spam filtering purposes, please copy the number 7679 to the field below:

Readers who viewed this page, also viewed:

Site Search

RSS Feed

Subscribe by email

Explore India Technology Bloggers (a FeedBurner Network)