How Do I Position Adsense With CSS?

They have: 43 posts

Joined: Sep 2005

Hey All,

I use google's adsense on my site, and I've been trying to find out how to put all the google javascripts at the bottom of the html, but still have the ads appear in the right places (banner, margin).

I tried absolute positioning but then the ads show up under the footer. Of course, I could have written it wrong:
In my css:
navad {
position: absolute;
top: 200px;
left: 14px;
}

In my html, just above /body:

BTW, my site has 5 main divs: two margins, header, content and footer.

Anybody now how to do this? TIA!

Renegade's picture

He has: 3,022 posts

Joined: Oct 2002

Firstly, you forgot the # in your CSS, so, it should be

#navad {
position: absolute;
top: 200px;
left: 14px;
}
'

Secondly, the HTML is wrong, try:

<div id="navad"><javascript stuff></div>
'

They have: 43 posts

Joined: Sep 2005

Ah, thanks. I only understand css by experimentation and comparisons between pre-made templates, so my understanding is incredibly fragmented.

So I now I'm able to position javascripts way at the bottom.

Thx again!

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.