Test Footer

Hide Ads on a Particular Post or Page

Hide ads on blogger postThis was a hack that I always wanted for a long time, especially since most of us have our ads under the headlines of the post which is a very very hot spot :) It does look ugly to an extent and sometimes you would like a particular post or page to look neat, like a contact page or a page displaying some particular art work you would like to sell.

No one had a hack on blogger until recently Geek Blogger came up with one on his best how to blogger.

First, your gonna have to back up your template prior to making any changes. Then the next step is to locate your ad code. Once you have your ad codes you need to put a div code as shown below.

<div id="MyAds1">
Your Ad Code is Here
</div>


Once that is done you can save your template and then go to the post where you would like to hide the ads, at the end of the post paste the code below.

<script type="text/javascript">

var Ads1 = document.getElementById('MyAds1');

Ads1.parentNode.removeChild(Ads1);

</script>


If you have more than one ad on your page then you can hide the one on top as this method does not work to hide two ads. I do hope you liked our second hack from Blogger Blog Templates. Subscribe to get the next hack delivered to your email!

No comments:

Post a Comment