Gogi's Technology Blog

Home » WordPress » WordPress Thesis Theme: How to wrap text around Google Adsense

WordPress Thesis Theme: How to wrap text around Google Adsense

by Gogi Rana on February 26, 2011 · 10 comments

In order to increase the ads CTR you need to place the Google Adsense codes at a higher placement on your site. Google Adsense does well when placed ATF (Above the Fold), i.e. before the user scrolls down to view the rest of the content.

Google ad size 336×280 is one of the best performing ad and it can earn you the most revenue when used next to the content wrapped around the ad. You can easily create that effect on WordPress Thesis Theme using simple codes.

Before we begin you should be using the Thesis theme and should have Thesis OpenHook installed.

How to wrap text around adsense in Thesis Theme

  1. In Appearance look for the Thesis OpenHook link and click it.
  2. When you get the Thesis OpenHook page find “Before Post”
  3. For the Before Post box add the following code listed below and save it.

<?php

if (is_single()) { ?>

<div style=”float:left;margin-right:8px”>

{Your AdSense code ad size (336×280) goes here}

</div>

<? } ?>

This simple code will add the 336×280 AdSense ad on every single post page that will float on left side and right side you can see the text wrapped around the ad.  In case you want the ad to be shown on the right side change the float: left to float: right.

Appearance openhook setting

Appearance openhook setting

Google AdSense wrapped around text in thesis theme

Google AdSense wrapped around text in thesis theme

 

 


Subscribe Now and get Free updates
Direct to your Email (Daily Digest or as and when a new post is added) or via RSS.

Share

{ 10 comments… read them below or add one }

Juha December 6, 2012 at 10:10 pm

The code does not work if you just copy this code because of the brackets. You have to change bracket from ” to “.

Reply

Harman December 3, 2012 at 10:00 pm

Thanks, This finally worked!

Reply

Pulsometros February 27, 2012 at 7:15 am

The script works, I'm using it before post, exactly where it says "Equivalent to adding to thesis_hook_before_post in your custom_functions.php file." The adsense ad is placed below the title and before the content, but the static post text is not wrapping around the ad. any idea?

Reply

GoGi February 27, 2012 at 12:05 pm

Hi,
look at the double quotes its ” in ”float:left;margin-right:5px" change the quotes to "float:left;margin-right:5px"
Better if you manually edit the quotes instead of copy paste.

Reply

Rasel Rony February 22, 2012 at 10:42 pm

thanks for the tutorial, but I'm using Quick Adsense plugin, its awesome for showing adsense ads anywhere

Reply

Irfan January 24, 2012 at 6:36 pm

but guys this code perfectly worked for me and now i have solved my problem.

Reply

single mom dating January 5, 2012 at 11:11 am

I cannot get this code to work either.

Reply

GoGi January 5, 2012 at 12:26 pm

Hi,
Can you let me know the issues?

Reply

Rajasthan December 28, 2011 at 5:09 am

I think this information is good for those who are fed up with ad sense, still have traffic on their sites/blogs and can earn decently.

Reply

Teaching Opportuniti November 2, 2011 at 12:31 pm

Hey,

This code does not work.

Reply

Leave a Comment

Previous post:

Next post: