homepage Welcome to WebmasterWorld Guest from 54.243.12.156
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe to WebmasterWorld
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
optimizing page rendering time
... with dynamic ads
disgust




msg:3983380
 2:41 pm on Sep 3, 2009 (gmt 0)

if you include an image on a website and you don't specify width and height, it won't render until it fetches the image. I understand this.

but I'm wondering how it works with ads, say tribalfusion/etc.

if in the middle of a page I have the ad code, does it need to analyze the ad code, fetch the ad, etc, before rendering?

if it does, can this be fixed by simply putting the ad code within a div that specifies its height/width?

if that trick does work, then how do you deal with ads that may serve in different sizes-- for example, tribalfusion has code to load a 728x90 leaderboard. if there's no inventory for that individual ad, it could serve a 460x60 banner ad instead.

I need ads on this particular site, but I'd like to still keep page load time to a minumum

 

penders




msg:3983915
 10:38 am on Sep 4, 2009 (gmt 0)

If you specify the width and height of an image, the browser will merely reserve the space required for the image in the page - it still won't render until it fetches the image - it will just prevent the page contents from moving around when the image headers are fetched.

if in the middle of a page I have the ad code, does it need to analyze the ad code, fetch the ad, etc, before rendering?

if it does, can this be fixed by simply putting the ad code within a div that specifies its height/width?

Placing the ad within a DIV does not effect the rendering, or the time it takes to render. It will reserve the space in the page for the ad and prevent the page from moving around as the page loads (just like an image) - this might give the illusion that the page is loading quicker, but it isn't really.

IMHO you should reserve a fixed area of your webpage for the ads and confine the ad to a fixed width/height container.

...then how do you deal with ads that may serve in different sizes-- for example, tribalfusion has code to load a 728x90 leaderboard. if there's no inventory for that individual ad, it could serve a 460x60 banner ad instead.

Set your (DIV) container to the max size the ad could be. If you allow the ad to determine the layout of your page then I can imagine it getting messy. What's the 'inventory'? Ad space is often sold according to size. I would have thought you should be able to control the size of the ads served at the ad server?

As for page rendering time... I'm not sure how you can improve on this with dynamic ads, unless you attempt to cache them somehow, but then they are no longer truely dynamic. I think you are dependent on the rendering engine of the ad server.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About
© Webmaster World 1996-2014 all rights reserved