Forums

AdSense not working in pre-existing theme slots! (12 posts)

  1. crobs808
    Member
    Posted 3 years ago #

    Hey everyone,

    I have a theme that came with pre-existing 125x125 ad slots as well as a horizontal ad unit slot on the top of the blog, see here:

    http://www.corusa.com/

    Now, I have Adsense-manager installed, but when I go to ad my ad to the widget bar, it creates a new slot underneath the 4 already esiting ones....I need it to use those slots. Also, I only wasnt 3 on a page, so I want to use the top horizontal ad and two of the 125x125 boxes, and delete the other two 125x125 boxes

    So, how do I use the pre-existing ad slots?

    THANKS

  2. myinstinctwaswrong
    Member
    Posted 3 years ago #

    on my theme, I had to manually insert the code for the pre-defined ad slot (my theme only had one). Then I used the Adsense widget to add more adsense code dynamically in my between my posts. Interestingly enough, I set the Adsense widget to a limit of 3 ad units - and it counts the pre-defined one that is in the header.

    I think you will have to edit your theme files to remove the unwanted pre-defined areas.

  3. crobs808
    Member
    Posted 3 years ago #

    is there a way to delete the 125x125 pre-set slots altogether? and just use the widgets you manually add?

    i'd like to do that, except for the top banner...i need to know what code to change to put a AdSense ad there.

  4. myinstinctwaswrong
    Member
    Posted 3 years ago #

    on my theme, I just edited the header.php file. In your theme header.php file, locate this

    <img src="http://corusa.com/blog/wp-content/themes/Choc/images/!ban.gif" alt="banner" />

    and replace it with the code you get from your google adsense account for a 468x60 banner ad. The theme lists it as a 480x60 ad, but adsense will provide 468x60, so it will leave you some spacing.

  5. myinstinctwaswrong
    Member
    Posted 3 years ago #

    your 125x125 are probably in the index.php file, listed in your page source as

    <div id="body_right">
    <div id="body_right_content">

    <div id="right_ads">
    <div>
    <img src="http://corusa.com/blog/wp-content/themes/Choc/images/!ads.gif" alt="ads" />
    </div>
    <div class="right">
    <img src="http://corusa.com/blog/wp-content/themes/Choc/images/!ads.gif" alt="ads" />
    </div>
    <div>
    <img src="http://corusa.com/blog/wp-content/themes/Choc/images/!ads.gif" alt="ads" />
    </div>
    <div class="right">
    <img src="http://corusa.com/blog/wp-content/themes/Choc/images/!ads.gif" alt="ads" />
    </div>
    </div>
    <div class="clear"></div>

    if you only want two blocks, then delete the others.

  6. crobs808
    Member
    Posted 3 years ago #

    i tried replacing that EXACT text you told me to replace for the banner with the google adsense text, but now I get a banner that says "page not found"

    whats the deal? i made sure that i did not paste of anything that you didnt tell me do. i replaced the exact text you typed

  7. crobs808
    Member
    Posted 3 years ago #

    oh, i also had to remove the "" code too

  8. crobs808
    Member
    Posted 3 years ago #

    that's "< a href = # >" code...forgot to put spaces in my last post, so it translated it as html, lol

  9. myinstinctwaswrong
    Member
    Posted 3 years ago #

    yes, you are correct about removing the a href stuff - my mistake to not include that.

    When I first did mine, I also got the page not found thing - I let it go while I worked on other changes and the problem worked itself out, so I never spent any time trying to figure out what was going on.

  10. myinstinctwaswrong
    Member
    Posted 3 years ago #

    I just looked at your site - I see 2 ads - one 468x60 at the top, and a 125x125 (or so) underneath the 4 predefined slots.

  11. crobs808
    Member
    Posted 3 years ago #

    i check for the 125x125 one, in index.php, there is no ad code in there at all. what page contains the 125x125 preset code? because it isnt in sidebar.php eiher.

  12. myinstinctwaswrong
    Member
    Posted 3 years ago #

    I don't know for sure - I just figured it was in the index.php file since the CSS div is "body_right". you will need to dig around a bit.

    Don't you think the 125 one that is displaying is probably added by your Adsense manager widget thing-a-ma-jig?

Topic Closed

This topic has been closed to new replies.

About this Topic