• I know there’s a plug-in for Adsense – however, i think it was written for Wp 1.2 and also it only puts the adsense in the banner format on top of the most recent post

    Is it possible to put the adsense next to the post itself, for example side by side with the most recent post, (NOT the sidebar!) perhaps in a vertical manner, and the text of the post adjusting to fit the Google ad…(try to visualize)

    pls help – it’ll be great if there’s a plugin for this

    thanks

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter brandon88

    (@brandon88)

    Some help here plse??

    Where is your WP site ?
    What have you tried ?

    I use the Adsense plugin from Phil Hord that provides a quicktag to place the ad block inside a post, inside a CSS styled <div> to make the text wrap around the ad block.

    You need to be careful about how this is used to prevent multiple ad blocks showing in archives etc (refer to the Google TOS) – I only show one post at a time so have avoided the issue.

    Hope this works for you.

    I installed the adsense plugin and works great but I haven’t figured out how to wrap text around the smaller Google blocks. Would be very apprciative f some very specific insructions on how to do this.

    Thanks

    I should have a plugin eventually that’ll do most of this for you… for the moment:

    <div class="adsense">{{some adsense stuff}}</div>

    – change class=”adsense” to “adsense-wide” or “adsense-tall” or whatever, to REALLY specify what the size/orientation is. That’ll allow you to use different sized ads and CSS them differently.

    – in CSS, you then do something like:

    .adsense {
    float:right;
    padding: 10px;
    padding-right: 0;
    }

    – You can have up to three adsense blocks per page. After the third, they ‘self-destruct’ and don’t show anything. But better to code it to know how many blocks you have and not try to show it again. ??

    That what you’re looking for? This is basically how I do my floating amazon product blocks in posts with CG-Amazon+CG-Inline. (Check any product news posting on my site as it’s a good ‘example’ page. ?? ).

    -d

    I use the AdSenseDeluxe plugin which allowed me to customize various ad sizes. I can pick from these various sizes at the time I create a post, use the one that best fits the size of that post, and drop it right in where I want it. Also, I wrap all my ads in DIVs to position them based on CSS classes I added into the theme CSS. It all looks fine and validates perfectly to XHTML 1.0 strict.

    BTW, I place AdSense in every single post even though I display five posts per page. I let Google sort out which are the first three and drop the rest. It doesn’t hurt anything to have more than three; it just ignores the rest. This way I have an ad display even if someone views a single specific post or category.

    brandon,

    In single.php or page.php you’re best bet is to use the method suggested by davidchait. Take the adsense code and place it in a div, you can then float that div appropriately before the wordpress “the_content” tag. This will place the ad right next to the beginning of the post. (Depending on your writing style it’ll sit next to the first paragraph or so of your post. Just remember that you’ll encounter problems if you try adding an image or other block items at the start of anything new.)

    On index.php you need to add an additional step. Because the AdSense TOS restricts you from placing more than three blocks of code on any page you’ll need to add some PHP to prevent the code from repeating more than you’d like.

    I’ve written a small post on “offsetting” posts which you can look at for some ideas.

    While ptvguy is correct, multiple occurences of the code won’t display anything, it does appear to be a breach of the AdSense Program Policies and should be avoided.

    While ptvguy is correct, multiple occurences of the code won’t display anything, it does appear to be a breach of the AdSense Program Policies and should be avoided.

    Sorry, I hadn’t looked back at this page in a while. I was incorrect in stating that Google was responsible for stopping after three adblocks. Actually, the AdSenseDeluxe plugin itself prevents more than three from appearing on any one page. It’s coded into the PHP. Once the plugin places three adblocks, it simply quits adding them–no matter how many you put. That means that you’re free to place them in every single post and let the plugin keep you from violating Google’s TOS.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Put AdSense next to the post instead of top of post’ is closed to new replies.