views:

28

answers:

0

First, I'm talking about Double Click for Publishers, formerly known as Google Ad Manager (GAM).

Some sites I manage use a fluid layout, and therefore, depending on a browser's width, the page's height can vary. This translates into more or less ad real estate.

I am taxed with the chore of maximizing ad display: On pages with little content, show fewer ads, and on pages with more content (or tall pages due to narrow browser width) show more ads.

In short, the site owners want to avoid huge blocks of white space in either location; the content column or ad column. We want the height of the content and the combined height of advertisements to align (within reason) no matter the user's browser and screen size.

I know how to calculate the height and available space once the page is loaded (thank you JQuery!). I need help/feedback on Google's code.

I'll refer to this page since its cleanly divides the sections I'm talking about: "What tags do I need to run DFP Small Business on my site?"

It divides the JavaScript into 6 steps.

I plan on doing steps 1 - 3 server side, and steps 4 - 6 client side, based on my on-load page height calculations.

Is there anything I need to be wary of regarding steps 4, 5, and 6 when tackling them client side?