There were many wordpress plugins that perform this task easily, but doing so might eventually increases your wordpress blog’s loading time..
And so, its better to manually perform this task as you can insert adsense ads anywhere inside your wordpress using just a shortcode.
How to Insert Google Adsense Ads Inside Your WordPress Posts?
- Go to Dashboard -> Appearance > Editor
- Open functions.php file
- Insert the following piece of code anywhere in the functions.php file
function showads() {
return ‘<script type=”text/javascript”><!–
google_ad_client = “pub-1234567891011122″;
google_ad_slot = “4668915978″;
google_ad_width = 468;
google_ad_height = 60;
//–>
</script>
<script type=”text/javascript”
src=”http://pagead2.googlesyndication.com/pagead/show_ads.js”>
</script>
‘;
}
add_shortcode(‘adsense’, ‘showads’); - Save changes.
Categories:
Adsense Tips And Help





