Joining my HTML output into a single line (Google does it)

Cliff Wells cliff at develix.com
Wed Oct 22 23:38:57 MSD 2008


On Wed, 2008-10-22 at 18:36 +0200, Redd Vinylene wrote:
> On Wed, Oct 22, 2008 at 3:35 PM, jeff emminger <jemminger at gmail.com>
> wrote:
>         On Fri, Oct 17, 2008 at 9:57 AM, Redd Vinylene
>         <reddvinylene at gmail.com> wrote:
>         > Can nginx help me join my HTML output into a single line?
>         >
>         
>         
>         Why bother?  What's it going to save... 100 bytes?  Gzip seems
>         better
>         if you're just trying to compress.
>         
> 
> For the same reason architects build their buildings according to set
> sizes.
> 
> For the same reason          I    don't
> 
>        type
> 
> 
> 
> 
> 
> 
> 
> 
>                                like
> 
> 
> 
> this

That makes no sense.  If anything this is an argument against having
your HTML all on one long line.  If you are looking for human-readable
HTML formatting you should consider tidylib or just make sure you are
generating formatted output to start with.

For the record, I consider lossless compression (e.g. gzip) much more
reliable than whitespace collapsing if you are looking to conserve
bandwidth.  It's more effective, plus it's nearly impossible to debug
layout issues if your output gets mangled before you see it. 

Cliff







More information about the nginx mailing list