How to Insert Ad Anywhere In Your WordPress Posts

Pin It

This is the simplest trick to guide you how to Insert Ad Anywhere In Your WordPress Posts. You may can put any advertise banner or google adsense using this small WordPress Hack without a plugin.

Step 1:
First open your WordPress Theme function.php file and add following function and save the file.

function showads() {
    return '

Your Advertise Banner or Google Adsense Code Here 

';
}
add_shortcode('adcode', 'showads');

Step 2:
Once you added this code, you can embed your ad code anywhere in your WordPress Post exactly where you want by putting [adcode] in your post HTML.

You can also learn How to Insert Ads Inside Post Content in WordPress Automatically by this simple WordPress Tutorial.

Most Related Tutorials

Leave a Response

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>