Google adsense on test results

Okay here it is my site runs smooth and fast however the test results also show adsense, the adsense takes 12 seconds to load. How is this my fault, there is nothing i can do to effect adsense, if they decide to run .flv movies from universal studios how can i stop that :huh:

So every time i run webpagetest it tells me i have a slow site because of adsense.

Umm, technically, if you have a slow site because of adsense, you have a slow site (the same could be said for any other 3rd party widget you put on your site like facebook like buttons, etc) :wink:

More seriously, for recent browsers (IE 8+), adsense should load asynchronously now so even if it is slow your page content should not be delayed because of it. You should probably verify by enabling the video capture for a test and make sure the page content loads quickly.

If you want to test the site in isolation and remove the adsense impact from the times you can use the content blocking feature in the advanced settings and block the adsense js (and you can also do a comparison video against the normal site to see the real user impact).

http://www.webpagetest.org/result/110516_H9_M6H6/1/details/

There is a huge load on my site because of adsense, i’m not going to take it off. So what can i do.

Here is a comparison of the site with and without adsense: http://www.webpagetest.org/video/compare.php?tests=110516_02_4bb05c0824dac4c535511eeb322059ad,110516_QN_39f043d539e5b1603fc3b45b5df8ca48

I think you were seeing some really long loads because of a video ad that played after onLoad but the impact to the actual page itself loading looks like it’s only ~100ms (using IE8 which has the async support in adsense).

The only reason I recommended blocking adsense for running a test was so you could see if you had any room for optimization outside of the ads and to get a cleaner read on the page itself: http://www.webpagetest.org/result/110516_QN_39f043d539e5b1603fc3b45b5df8ca48/

Looking at the waterfall, I’d say your best bet for optimization is to actually focus on the back-end page generation. Looks like it is taking a little over 600ms to construct the html on the server side. A quick trick would be to get early flushing working so you could flush out enough of the html to get the browser loading external resources while you work on the more expensive back-end calls.

early flushing sounds like a new concept to me i’ve never heard of this before anywhere good i can research this :confused:

Here you go: Flushing the Document Early | High Performance Web Sites

You can also Google for “flush document early” to get more information.

thanks for the help it was really helpful now i have a little new performance tool to learn :slight_smile:

However after doing research into flushing they say the way to do it with php, is adding the code

<?php flush(); ?>

after the

in my index.php page, i’m using joomla and after putting it there expecting it to work nothing happened i’m still getting the slow initial slow response that it said it would fix no difference :frowning:

In php there can be some interactions with output buffering so sometimes you need to use ob_flush() but if you’re running Joomla you might want to avoid that - there could be code in the templates that are counting on the buffers not having been flushed.

What version of Joomla are you running? Have you enabled the built-in page caching mechanisms? Joomla is one of the harder CMS systems to optimize because there aren’t a lot of plugins that can help (though there are a few threads around here from people working on it).

Confused before i even start (not good) i’m using the latest version of Joomla 1.5 and i’m using the built in page caching along with a CDN called maxcdn which gzips everything for me in advance. Wish there were more performance plugins for joomla but all you get are “compress css plugins” for the performance section of joomla and only a handfull of useful plugins that do something different :frowning:

i taken the

<?php flush(); ?>

off my site cause you said it may conflict with joomla.

Use Chrome Tools and there the console.
There 9 errors like that.

I’m just using the feature in Google adsense where it says “Edit adsense unit” ([size=small]Show non-Google ads from another URL[/size])you put in a .html page where the other ads are, in my case i use adbrite ads if there are no adsense ads available. Unsure if i can so anything about this, seems to be an error on Googles side. Thanks for letting me know though as i only use firefox or Opera to check my code :slight_smile:

Did you place it on the site yourself? If someone else in your organization placed it there, then it’s his/her fault (unless you are in charge of the staff member, in which case, it is still your responsibility/fault).

But seriously, I don’t place ads, especially AdSense ads, on important landing pages.