WordPress.org

Ready to get started?Download WordPress

Forums

Center a widgetized adsense-ad (7 posts)

  1. Anders Norén
    Member
    Posted 5 years ago #

    I am currently adjusting all of the ads on my site, still in development. I have included a wide skyscraper in the sidebar, but it doesn't look quite right. It isn't wide enough. So I figured that I'd just center it – which brings me to my problem. I don't know how to.

    At first, I placed a text-widget above it with "<center>" as text, and one beneath it with "</center>". It worked for IE, but not Firefox. Any other suggestions would be greatly appreciated.

  2. Qliphoth
    Member
    Posted 5 years ago #

    Try <div align="center"> and </div> instead.

  3. Anders Norén
    Member
    Posted 5 years ago #

    Try <div align="center"> and </div> instead.

    Hmm. No, didn't work. I'm guessing that the div is intervening with something as well, as the background disappeared.

  4. Anders Norén
    Member
    Posted 5 years ago #

    Never mind, I solved it. For future reference: I took the original code from Adsense, pasted it in a text-field and used the <center>-tag. Should have thought of it earlier.

  5. brad8585
    Member
    Posted 5 years ago #

    instead of adding it to the text widgets above/after the adsense code, add a <center> and </center> into the actual adsense code.

    It's ugly but it works :)

  6. danieldickey
    Member
    Posted 5 years ago #

    I'm putting <center> above the adsense code and it's centering my whole page? What am I doing wrong?

  7. danieldickey
    Member
    Posted 5 years ago #

    nevermind, I added </center> below it. Thanks so much.

    http://www.DanielDickey.com

    I put it under my header.

Topic Closed

This topic has been closed to new replies.

About this Topic