Google Releases mod_pagespeed for Apache
googlewebmastercentral.blogspot.com
googlewebmastercentral.blogspot.com
http://code.google.com/speed/page-speed/docs/filters.html
It will automatically strip inline css and js out of a html page and then create links to an external version. It will automatically set very long cache times. It minifies css and javascript on the fly, strips whitespace and comments from the html.
Then for images, it automatically rescales them, strips out meta data and recompresses. It even converts img tags to use data: uris when it's safe and efficient to do so.
I love it.
Is it compatible with Adsense policy?
Async Adsense: http://webmasters.stackexchange.com/questions/2506/is-it-pos...
Async Analytics: http://www.ditii.com/2009/12/01/google-analytics-asynchronou...
I don't know what's the second link for, as analytics are asynchronous per se?
EDIT: By the date on the second url, very probably is a hack for an older version of Analytics.
EDIT 2: First link is an unaccepted answer on an stackoverflow-like site on the topic for using an against the rules of Google hack. And Google doesn't need much help for closing your account and your money.
Here is another link for async adsense with code included. The author has also posted his e-mail conversation with a rep. from the Google Adsense team. There is nothing fancy going on here, just iframes, really.
http://geoland.org/2007/01/adsense-in-iframe/
You could just reach out to adsense yourself and report back what you find regarding violation of the Google Adsense TOS.
Do you fellow HNers know any way to speed up them or at least load them in the background?
Could you share any sample of adsense with scripts in the header? Also, do you know any way to load dynamically the scripts?
Google seems to be full of people trying to do it to no avail.
http://code.google.com/apis/analytics/docs/tracking/asyncTra...
I think this should be added to the risks list for this filter[2]. Does anyone know how to ping Google about such things?
[1] http://www.molly.com/2005/10/06/css2-and-css21-specificity-c... [2] http://code.google.com/speed/page-speed/docs/filter-css-outl...
I'm sure there is going to be tons of positives to this from the community, many I can identify myself, but can someone list some NEGATIVEs that may arise by using this?
The 'Inline CSS' filter is low to moderate risk. It should be safe for most pages, but it could potentially break scripts that walk the DOM looking for and examining <link> or <style> tags.
http://code.google.com/speed/page-speed/docs/filters.html
This is a tool that mindlessly applies optimisations that are lossy or change behavior of the page. Sometimes it may break things (e.g. I use `input[type=text]` selector in my CSS, and removal of "redundant" `type="text"` attribute from source would break it).
It also wastes some processing time on applying on-the-fly code changes you could do yourself in the source.
If you follow performance best practices, you may optimize pages better yourself (you need to judge what is better to inline, what can be made async. Simple heuristics of this module uses may be too crude).
These are different things kept roughly in sync by setters/getters (called "reflected properties" in HTML spec).
The `type` attribute is also supposed to have default value implied by the DTD, but that could only work in "validating" SGML/XML parsers (which browsers aren't).
Usually I do a lot of optimization in the templates. For example, Smarty lets you wrap your output in {strip} tags to remove whitespace and newlines. And I have a script to concatenate and minify javascript and css. Plus mod_deflate on the server. I serve images from s3/cloudfront and there is a script that will use smush.it to compress everything in an s3 folder and set the expires tags.
It's also another apache module. Personally I try and work without DSOs.
I wonder which filters Go Daddy will enable and how many problems it will cause.
Before: <img src="images/BikeCrashIcn.png" alt="Bike Crash">
After: <img src="images/images/ic.HASH.x,BikeCrashIcn,p.png" alt="Bike Crash">
If you get significant search traffic from Google or Bing Image Search you'll probably want to disable this filter.
The filter retains the original filename as well as the alt text.
From the horse's mouth: "optimizing your image filenames and alt text makes it easier for image search projects like Google Image Search to better understand your images."
http://static.googleusercontent.com/external_content/untrust...
Anything that makes it harder for Google to understand your site is a losing business proposition.
I'd rather use PageSpeed for Firefox (optimize in dev, set the appropriate filenames, then deploy to production) to avoid any possible ranking penalties caused by this filter in production.
It was these guys (the "speed" folks) within Google that came up with the idea.
http://code.google.com/speed/webp/
Maybe in a later version?
this is putting Google into our servers, too.
If apache rewrites the html with such things like temporary optimized versions of files, nginx presumably won't know anything about serving them, so it'll break (date urls being an exception here I guess).
For things like media, I really want to keep apache out of the loop completely.
edit: of course enhancing the internet increases the number and frequency of people interacting with their search, adwords on pages, and feeling comfortable with web apps (helping create lead for Google Apps B2B)
One thing that may not be obvious about minimization is that it does not yield much size reduction when coupled with gzip. You may see 30% decrease in size with minimization on the plain file, but when you gzip both the plain and minimized you may only see a difference for a couple of hundred bytes. If you are worried about speed, you should be using gzip for static content.
I'm all for optimizing the crap out of page serving, but if this is going to double our Apache load, a) I'd like to know about it ahead of time and b) it might be worth just applying optimizations by hand.
There's no details on it, but I wonder if GoDaddy has some plan to provide a way to turn specific things off. If not, this sounds like it could be a disaster.
Don't let developers be blinded by an automatic optimizer.
Edit: Yes, it does:
In order to rewrite resources, mod_pagespeed must cache them on the server.
It's awesome that they don't treat 'uncaptured synergy' as a release blocker like Microsoft would have.