How to Insert Ads Inside Post Content in WordPress

You may have seen many wordpress blogs showing ads inside post contents. This simple WordPress Tutorial guide you how to insert ads inside the post contents. You may put the ads after the first or second paragraph.

Wordpress Ad after first post

In this little WordPress Hack I will guide you how to put ad after first paragraph automatically in your everypost without any WordPress Plugin.

First open your single.php file from your current theme and search the following code:


Now Replace below code with it:

    ", $content);
    for ($i = 0; $i 

Your Text / Ads Go Here
"; } ?>

If you need, you can change the place after number of paragraphs by changing $paragraphAfter line.

Demo: MobiDhoom.com

About the author



Leave a Comment