By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,369 Members | 1,682 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,369 IT Pros & Developers. It's quick & easy.

Don't bother saving white-space

P: n/a
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
seen it suggested again a couple of times in the last few days, I
decided it was time for a test on the effect of white-space.

I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html

I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either) using Opera 7.

The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable. This suggests that if you took a file
with a fairly generous 5Kb of white-space, and stripped out all of it,
loading would be speeded up by a princely one-sixth of a second. (For
comparison, the largest HTML file on my site, of 79Kb, turned out to
have just under 3Kb of compressible white-space.)

Somehow it just doesn't seem worth it ...

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #1
Share this Question
Share on Google+
45 Replies


P: n/a
On Thu, 19 Aug 2004 20:49:58 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
seen it suggested again a couple of times in the last few days, I
decided it was time for a test on the effect of white-space.

I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html

I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either) using Opera 7.

The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable.


For me, original=3secs, bloated=21 secs.

The extra white space amounts to 142 Kb. Took me 18 extra seconds to load.
About 8Kb per sec, or close to the same for the original file. This would
seem to indicate there is value in reducing white space.
Jul 20 '05 #2

P: n/a
On Thu, 19 Aug 2004 15:00:09 -0400, Neal <ne*****@yahoo.com> wrote:
On Thu, 19 Aug 2004 20:49:58 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:
The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable.
For me, original=3secs, bloated=21 secs.

The extra white space amounts to 142 Kb. Took me 18 extra seconds to load.
About 8Kb per sec, or close to the same for the original file. This would
seem to indicate there is value in reducing white space.


That's interesting. I wonder what causes the difference? What browser
are you using? Are you using a 56Kb modem? - if so, it indicates that it
must be doing some compression, or the 'bloated' transmission would take
around 30 seconds.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #3

P: n/a
Els
Stephen Poley wrote:
On Thu, 19 Aug 2004 15:00:09 -0400, Neal
<ne*****@yahoo.com> wrote:
On Thu, 19 Aug 2004 20:49:58 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:
The first page loads in 3 seconds, the second in 8
seconds - both figures seem to be repeatable.

For me, original=3secs, bloated=21 secs.

The extra white space amounts to 142 Kb. Took me 18 extra
seconds to load. About 8Kb per sec, or close to the same
for the original file. This would seem to indicate there is
value in reducing white space.


That's interesting. I wonder what causes the difference?
What browser are you using? Are you using a 56Kb modem? -
if so, it indicates that it must be doing some compression,
or the 'bloated' transmission would take around 30 seconds.


I'm on broadband, the first is done within a second, the second
one takes 2/3 secs.

I suppose that could add up if you're working with 'flip-
through' pages, even for broadband.

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vo. O resto imperfeito.
- Renato Russo -
Now playing: Magnum - No Way Out
Jul 20 '05 #4

P: n/a
Stephen Poley <sb******************@xs4all.nl> wrote:
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS
I'd suggest that whitespace and comments are 2 different things.
in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
seen it suggested again a couple of times in the last few days, I
decided it was time for a test on the effect of white-space.

I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html
What you've done there is not typical coding whitespace, usually this
refers to blank lines (cr/lf pair on a line of it's own) and tabs, not
padding a document with spaces.
I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either)
56K is the theoretical maximum, in reality this is never achieved, sub
50K is pretty normal.
The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable.


I don't know anything about http protocol data compression, but note
that modem connections typically include the V42b protocol. V42b
provides real time compression up to 4x. Ascii data typically compresses
very well.

--
Spartanicus
Jul 20 '05 #5

P: n/a
On Thu, 19 Aug 2004 21:39:41 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:
On Thu, 19 Aug 2004 15:00:09 -0400, Neal <ne*****@yahoo.com> wrote:
On Thu, 19 Aug 2004 20:49:58 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:
The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable.

For me, original=3secs, bloated=21 secs.

The extra white space amounts to 142 Kb. Took me 18 extra seconds to
load.
About 8Kb per sec, or close to the same for the original file. This
would
seem to indicate there is value in reducing white space.


That's interesting. I wonder what causes the difference? What browser
are you using? Are you using a 56Kb modem? - if so, it indicates that it
must be doing some compression, or the 'bloated' transmission would take
around 30 seconds.


Opera 7.23 on dialup 56k, 45333 bps.
Jul 20 '05 #6

P: n/a
On Thu, 19 Aug 2004, Stephen Poley wrote:
I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html


It may be of interest that when gzipped, your file sizes came out as
7711 and 8805 respectively. So as we've been saying all along (well,
since NCSA X Mosaic had been supporting gzipped HTML about a decade
back, courtesy of jwz), there's far more to be gained by serving out
HTML gzipped than by fussing about a bit of white space.

thanks for the heads-up, though - no offence meant! ;-)
Jul 20 '05 #7

P: n/a
Stephen Poley wrote:
last few days, I decided it was time for a test on the effect of
white-space.

I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about
that number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html

I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either) using Opera 7.

The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable. This suggests that if you took a file
Here are two more data points for you, both over 24kbps modem from USA
west coast:

1) Firefox:
9 seconds vs. 13 seconds

2) wget:
D:\test>timethis wget -q
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html | grep "Elapsed"
TimeThis : Elapsed Time : 00:00:05.107

D:\test>timethis wget -q
http://www.xs4all.nl/~sbpoley/misc/checklist.html | grep "Elapsed"
TimeThis : Elapsed Time : 00:00:15.322

Living in an area without high-speed connections, I appreciate more than
most the value of fast websites, but I still indent and wrap my html.
Using your page as an example, it is 19135 bytes without any newlines or
duplicate spaces, and 20803 bytes indented and wrapped at column 72.
Tiny difference.
Somehow it just doesn't seem worth it ...


Yup. Optimize those jpegs instead.

Jul 20 '05 #8

P: n/a
Stephen Poley wrote:
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
seen it suggested again a couple of times in the last few days, I
decided it was time for a test on the effect of white-space.

I took one of my pages:
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.

I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html

I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either) using Opera 7.

The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable. This suggests that if you took a file
with a fairly generous 5Kb of white-space, and stripped out all of it,
loading would be speeded up by a princely one-sixth of a second. (For
comparison, the largest HTML file on my site, of 79Kb, turned out to
have just under 3Kb of compressible white-space.)

Somehow it just doesn't seem worth it ...


My opinion is that the total size (i.e. images included) is to be
considered.

According to http://www.websiteoptimization.com/ a analysis on your page
/webmatters/checklist.html gives this result

Total Size: 43638 bytes
HTML: 19685
Images: 18539
CSS: 5414
Total Images: 4
Download Times*
56K 8.90 seconds
Same analysis on the page misc/checklist.html

Total Size: 189818 bytes
HTML: 165865
Images: 18539
CSS: 5414
Total Images: 4
Download Times*
56K 38.03 seconds

So, if (at it looks) you don't change anything else than adding
whitespace to the code, the download time change with aprox 29 sec for a
56K dial up connection!

--
Arne
Jul 20 '05 #9

P: n/a
Spartanicus <me@privacy.net> wrote:
http://www.xs4all.nl/~sbpoley/misc/checklist.html


What you've done there is not typical coding whitespace, usually this
refers to blank lines (cr/lf pair on a line of it's own) and tabs, not
padding a document with spaces.


A more realistic example of documents with and without coding
whitespace:
http://www.pan-europe.utvinternet.ie...hite_space.htm
(50,066 bytes)
http://www.pan-europe.utvinternet.ie...hite_space.htm
(48,658 bytes)

In addition to the tab's and cr/lf's that I normally use I've added a
blank line between every line of code in the first document.

--
Spartanicus
Jul 20 '05 #10

P: n/a
In article <op**************@news.individual.net>,
Neal <ne*****@yahoo.com> writes:
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
Compression is optional in HTTP, and only works if you've enabled it
on the server (eg with mod_deflate).
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
which is 20 Kb.
HTTP compression is not enabled on that URL.
I then bloated it with whitespace to 162 Kb (nothing special about that
number - it's just what it happened to end up as):
http://www.xs4all.nl/~sbpoley/misc/checklist.html
Nor there.
I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either) using Opera 7.
I expect you have PPP compression enabled in your modem.
The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable.

That's a significant difference. If you had HTTP compression enabled there
should be negligible difference (because that extra 162K would be wiped out).
For me, original=3secs, bloated=21 secs.
Either you have no PPP compression (very bad), or you have a bottleneck
elsewhere in your connection.
About 8Kb per sec, or close to the same for the original file. This would
seem to indicate there is value in reducing white space.


Indeed, in some circumstances there is. But there is much more value
in mod_deflate. And if you use that, the value in reducing whitespace
vanishes. That applies to any repetitive patterns - such as HTML tags -
but not to comments (mentioned in passing in the OP).

--
Nick Kew

Nick's manifesto: http://www.htmlhelp.com/~nick/
Jul 20 '05 #11

P: n/a
On Thu, 19 Aug 2004, Stephen Poley wrote:
On Thu, 19 Aug 2004 20:41:12 +0100, Alan J. Flavell wrote:

http://www.xs4all.nl/~sbpoley/misc/checklist.html


It may be of interest that when gzipped, your file sizes came out as
7711 and 8805 respectively.


I have just been playing with various arcane
aspects of Zip compression over on c.l.j.p., so
I was particularly interested to see if you had ..

a) 'blobbed' the white-space in a large chunk, as opposed to
b) giving an extra space or two between each word,

...for example.

The reason is that most compression algorithms
will compress the 'large space' better than many
small spaces.

And.. yes, I noticed you made that mistake,
large chunks of whitespace that are easily
compressible, with a fairly clear pattern.

I would be convinced only if you started from
the outset with a more realistic (chaotic)
example.

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 20 '05 #12

P: n/a
I've switched to indenting my HTML out with tabs instead of spaces. It took
some getting used to as I didn't like how far they appeared to be indented
(I'm still a notepad junkie) but I got used to it and file sizes are much
smaller now (and my thumbs aren't as sore any more as I don't have to keep
hitting the space bar that much).
Jul 20 '05 #13

P: n/a
"Frostillicus" <fr****@nilspamos.iinet.net.au> wrote:
I've switched to indenting my HTML out with tabs instead of spaces.


You are trolling, are you not? As usual, crossposting to two groups
without setting followups is a probable sign of spamming, trolling, or
cluelessness, and a forged From field supports this impression.
So does lack of any reference to preceding discussion (such as quotation
or summary of the message being commented on).

In HTML, a tab is equivalent to a space, except in special occasions. But
almost any use of tabs in HTML is a symptom of some misunderstanding.

Followups trimmed. Indentation of HTML source is surely not a CSS
business.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Jul 20 '05 #14

P: n/a
On Thu, 19 Aug 2004 23:26:02 +0000 (UTC), Jukka K. Korpela
<jk******@cs.tut.fi> wrote:
"Frostillicus" <fr****@nilspamos.iinet.net.au> wrote:
I've switched to indenting my HTML out with tabs instead of spaces.


You are trolling, are you not? As usual, crossposting to two groups
without setting followups is a probable sign of spamming, trolling, or
cluelessness, and a forged From field supports this impression.


Odd you waited to tear him a new asshole when nine others, including me,
have participated in this crossposted thread prior. Unless I'm missing a
finer point, I hardly think it's fair. If I am missing a finer point,
apologies.
Jul 20 '05 #15

P: n/a
On Thu, 19 Aug 2004 21:37:07 +0100, Spartanicus <me@privacy.net> wrote:
Spartanicus <me@privacy.net> wrote:
http://www.xs4all.nl/~sbpoley/misc/checklist.html


What you've done there is not typical coding whitespace, usually this
refers to blank lines (cr/lf pair on a line of it's own) and tabs, not
padding a document with spaces.


A more realistic example of documents with and without coding
whitespace:
http://www.pan-europe.utvinternet.ie...hite_space.htm
(50,066 bytes)
http://www.pan-europe.utvinternet.ie...hite_space.htm
(48,658 bytes)

In addition to the tab's and cr/lf's that I normally use I've added a
blank line between every line of code in the first document.


I should perhaps have spelt things out a little more explicitly. The
point is that with realistic examples the difference in speed is too
small for me to measure (the same going for your example), so I made an
unrealistic example to see what happened.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #16

P: n/a
On Thu, 19 Aug 2004 23:26:02 +0000 (UTC), "Jukka K. Korpela"
<jk******@cs.tut.fi> wrote:
"Frostillicus" <fr****@nilspamos.iinet.net.au> wrote:
I've switched to indenting my HTML out with tabs instead of spaces.


You are trolling, are you not? As usual, crossposting to two groups
without setting followups is a probable sign of spamming, trolling, or
cluelessness, and a forged From field supports this impression.
So does lack of any reference to preceding discussion (such as quotation
or summary of the message being commented on).

In HTML, a tab is equivalent to a space, except in special occasions. But
almost any use of tabs in HTML is a symptom of some misunderstanding.

Followups trimmed. Indentation of HTML source is surely not a CSS
business.


Having a bad night, Jukka? The subject matter of the thread not only can
be, but has been, raised in respect of both HTML and CSS and it appears
to be relevant to both groups.

Further, given that tab is explicitly defined as a whitespace character
in HTML, your comment on that deserves a little further explanation.

(I'll grant you the comment on the lack of any quoted material.)

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #17

P: n/a
Stephen Poley <sb******************@xs4all.nl> wrote:
I should perhaps have spelt things out a little more explicitly. The
point is that with realistic examples the difference in speed is too
small for me to measure (the same going for your example), so I made an
unrealistic example to see what happened.


My example shows that there is no size issue, so you've created a
problem in order to demonstrate that if you create this problem it's not
as much of a problem as you may have thought before you created the
problem.

Huh?

--
Spartanicus
Jul 20 '05 #18

P: n/a
On Thu, 19 Aug 2004, Jukka K. Korpela wrote:
In HTML, a tab is equivalent to a space, except in special occasions. But
almost any use of tabs in HTML is a symptom of some misunderstanding.


Come again? I always use tabs to make my source more readable and
I cannot see what should be wrong with it.

--
Top-posting.
What's the most irritating thing on Usenet?

Jul 20 '05 #19

P: n/a
Jukka K. Korpela said the following on 20/08/2004 01:26:
"Frostillicus" <fr****@nilspamos.iinet.net.au> wrote:
I've switched to indenting my HTML out with tabs instead of spaces.
You are trolling, are you not?


I don't think Frostillicus was, but are you?
As usual, crossposting to two groups
without setting followups is a probable sign of spamming, trolling, or
cluelessness,
Then why do you blame him for that? Stephen Poley started the thread and
he didn't set a followup, nor did the 12 others who replied (by that
time) to it. Not that I see a reason for setting it, since it's relevant
to both groups.
and a forged From field supports this impression.
Sure .. it's one big conspiracy.
So does lack of any reference to preceding discussion (such as quotation
or summary of the message being commented on).
I think it's more productive to explain what people did wrong (according
to your beliefs or to nettiquette) than just picking on them. If you
explain it people might understand why some things are better or
preffered. I had problems with anyone saying that top posting was wrong
untill somebody took the time to explain it to me. Result: I don't top
post anymore.
In HTML, a tab is equivalent to a space, except in special occasions. But
almost any use of tabs in HTML is a symptom of some misunderstanding.
You didn't get the point. It wasn't about how a tab or a space is
*rendered*, it's about (source)file *size* (as was mentioned, but you
didn't quote *that* part). One tab is one character, serveral spaces are
several characters. It's plain simple.
Followups trimmed. Indentation of HTML source is surely not a CSS
business.


How about indenting CSS files? If you took the time to think about it,
you would see that his point is as valid for HTML as CSS (although the
later one wasn't mentioned).

--
Regards
Harrie
Jul 20 '05 #20

P: n/a
Harrie wrote:
Jukka K. Korpela said the following on 20/08/2004 01:26:
Followups trimmed. Indentation of HTML source is surely not a CSS
business.

How about indenting CSS files? If you took the time to think about it,
you would see that his point is as valid for HTML as CSS (although the
later one wasn't mentioned).


Right! And how about indenting PHP, ASP, JS, CFM, ... C, C++, C#,
Pascal, VisualBasic, etc ad infinitum? I think the list of crossposts
should be extended to cover all those other code newsgroups as well!
Matthias

Jul 20 '05 #21

P: n/a
On Thu, 19 Aug 2004 20:55:33 +0100, Spartanicus <me@privacy.net> wrote:
Stephen Poley <sb******************@xs4all.nl> wrote:
I tested them over my 46 Kbps modem connection (yes: 46, not 56; don't
ask - I don't know either)


56K is the theoretical maximum, in reality this is never achieved, sub
50K is pretty normal.


OK. In a previous configuration I always got 56 (to the nearest K), so I
assumed that was normal.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #22

P: n/a
On Fri, 20 Aug 2004 08:34:47 +0100, Spartanicus <me@privacy.net> wrote:
Stephen Poley <sb******************@xs4all.nl> wrote:
I should perhaps have spelt things out a little more explicitly. The
point is that with realistic examples the difference in speed is too
small for me to measure (the same going for your example), so I made an
unrealistic example to see what happened.


My example shows that there is no size issue, so you've created a
problem in order to demonstrate that if you create this problem it's not
as much of a problem as you may have thought before you created the
problem.

Huh?


<grin> Sort of. Given that the problem was too small to measure, I
attempted to ludicrously inflate the problem so as to be able to measure
it and demonstrate exactly how small it was. Or something.

I suspect we're violently agreeing with each other.

But I'm still intrigued by Neal's result, where he seems to get a little
compression, but not much.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #23

P: n/a
CJM
"Matthias Gutfeldt" <sa************@gmx.net> wrote in message
news:2o************@uni-berlin.de...

Right! And how about indenting PHP, ASP, JS, CFM, ... C, C++, C#,
Pascal, VisualBasic, etc ad infinitum? I think the list of crossposts
should be extended to cover all those other code newsgroups as well!


Matthias,

It's quite honourable to run to the defense of one of your pals, but this
attempt was quite lame, and entirely facetious.

The arguments about saving space are as applicable to CSS as they are to
HTML. Arguably you could say the same about ASP, PHP etc, except that what
the server transfers to the client (post-processing) is in fact HTML so we
are back to square one...

I dont think that C, C++, C# Pascal & VB have an relevance here, but even if
they did, it would break another rule of netiquette to include them all
in... Thou shalt no cross-post to more than 3 or 4 NGs! So the OP made an
entirely sensible choice.

The bottom line is that Jukka went off half-cocked. His stance on the
netiquette was arguable, he is technically wrong about the tab v. space
argument, and his silence is deafening.

Apart from this detour, this has been an interesting thread. Thanks Stephen.

Chris
Jul 20 '05 #24

P: n/a
On Fri, 20 Aug 2004 16:43:41 +0200, Matthias Gutfeldt
<sa************@gmx.net> wrote:
Harrie wrote:
Jukka K. Korpela said the following on 20/08/2004 01:26:
Followups trimmed. Indentation of HTML source is surely not a CSS
business.

How about indenting CSS files? If you took the time to think about it,
you would see that his point is as valid for HTML as CSS (although the
later one wasn't mentioned).


Right! And how about indenting PHP, ASP, JS, CFM, ... C, C++, C#,
Pascal, VisualBasic, etc ad infinitum? I think the list of crossposts
should be extended to cover all those other code newsgroups as well!


If it had been, it would not have been essentially wrong. At this point,
however, adding them in would be senseless.
Jul 20 '05 #25

P: n/a
CJM wrote:
"Matthias Gutfeldt" <sa************@gmx.net> wrote in message
news:2o************@uni-berlin.de...
Right! And how about indenting PHP, ASP, JS, CFM, ... C, C++, C#,
Pascal, VisualBasic, etc ad infinitum? I think the list of crossposts
should be extended to cover all those other code newsgroups as well!

Matthias,

It's quite honourable to run to the defense of one of your pals, but this
attempt was quite lame, and entirely facetious.


CJM, pal, why are you taking all this so dead serious? It's Friday
afternoon. Relax!
Matthias

Jul 20 '05 #26

P: n/a
On Fri, 20 Aug 2004 16:55:42 +0200, Stephen Poley
<sb******************@xs4all.nl> wrote:

But I'm still intrigued by Neal's result, where he seems to get a little
compression, but not much.

As am I. Checked modem properties, compression is on. Perhaps it's related
to my ISP, interference in the phone line, etc. It could be a lot of
things...

Just re-checked. The compact test was about 5 seconds, the spaced-out one
9 or 10. So this time there seemed to be compression. So I'll write off
the last results to some issue in the pipeline.
Jul 20 '05 #27

P: n/a
CJM

"Matthias Gutfeldt" <sa************@gmx.net> wrote in message
news:2o************@uni-berlin.de...

CJM, pal, why are you taking all this so dead serious? It's Friday
afternoon. Relax!
Matthias


Probably *because* it's Friday afternoon.... I want to go home.

Apologies if I misread the tone, but this seemed like a good thread going
sour....

Chris
Jul 20 '05 #28

P: n/a
CJM

"Stephen Poley" <sb******************@xs4all.nl> wrote in message
news:ij********************************@4ax.com...

OK. In a previous configuration I always got 56 (to the nearest K), so I
assumed that was normal.


<choke>I've never had > 45, and usually nearer 40!</choke>

Still, BT promised to give us broadband by end-2005.... T-480 days and
counting...
Jul 20 '05 #29

P: n/a
Andreas Prilop <nh******@rrzn-user.uni-hannover.de> wrote:
On Thu, 19 Aug 2004, Jukka K. Korpela wrote:
In HTML, a tab is equivalent to a space, except in special
occasions. But almost any use of tabs in HTML is a symptom of some
misunderstanding.


Come again? I always use tabs to make my source more readable and
I cannot see what should be wrong with it.


People often try to use tabs to tabulate data in HTML documents. Outside
<pre> (and perhaps <textarea>) elements it is doomed to fail. Inside
<pre>, it might work on sunny afternoons, but all HTML specifications
have told authors they should not really rely on that.

As regards to formatting HTML source, tabs may take you to some tab
stops, or they may not, depending on the program you're using. I don't
see why you would use tabs, when spaces work so much more reliably - who
knows what programs you might use for editing HTML in the future?

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

Jul 20 '05 #30

P: n/a
Stephen Poley <sb******************@xs4all.nl> wrote:
56K is the theoretical maximum, in reality this is never achieved, sub
50K is pretty normal.


OK. In a previous configuration I always got 56 (to the nearest K), so I
assumed that was normal.


Most unlikely, likely: your DUN reported DTE instead of DCE speed.

DTE is the comport speed and it's a common misconfiguration. Ever seen
people reporting that their modems connect @ 115KBps? Same cause :)

--
Spartanicus
Jul 20 '05 #31

P: n/a
On Fri, 20 Aug 2004, Jukka K. Korpela wrote:
Come again? I always use tabs to make my source more readable and
I cannot see what should be wrong with it.
As regards to formatting HTML source, tabs may take you to some tab
stops, or they may not, depending on the program you're using.


If not, then the program treats tab as a single space and nobody
is harmed.
I don't see why you would use tabs,
Because a tab says more than 1000 spaces - so to speak ;-)
I save lots of space characters for a single tab.
when spaces work so much more reliably


In what respect is a space more reliable than a tab? And what
about newlines? Don't you have any newlines in your souce text?
Space, tab, newline are equally valid white space.

--
Top-posting.
What's the most irritating thing on Usenet?

Jul 20 '05 #32

P: n/a
Andreas Prilop <nh******@rrzn-user.uni-hannover.de> wrote:
In what respect is a space more reliable than a tab?


A space forwards exactly one character position. A tab may forward to the
next tab stop, and tab stops are set differently in different programs.
This is relevant, since this was about using tabs for formatting HTML
source.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

Jul 23 '05 #33

P: n/a
JRS: In article <0m********************************@4ax.com>, dated
Thu, 19 Aug 2004 20:49:58, seen in news:comp.infosystems.www.authoring.h
tml, Stephen Poley <sb******************@xs4all.nl> posted :
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times.


However, some authors - probably including many of those here - should
configure their white-space for readability.

That, IMHO, means using blank lines and indentation to indicate
structure; but not indenting by a tab at a time, which generally leads
to the right-hand end of lines being a long way from the left margin,
which is inhumane. And leads to wrapping in News.
Depending on the editor used, it may be worth stripping trailing white
space. That tends to accrue; and is trivial to remove, at great speed,
with a tool such as MiniTrue. I saved several percent the first time
that I did it.

Those whose servers allow them restricted storage space may also benefit
from white-space reduction.

--
John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 MIME.
Web <URL:http://www.merlyn.demon.co.uk/> - FAQish topics, acronyms, & links.
I find MiniTrue useful for viewing/searching/altering files, at a DOS prompt;
free, DOS/Win/UNIX, <URL:http://www.idiotsdelight.net/minitrue/> Update hope?
Jul 23 '05 #34

P: n/a
On Fri, 20 Aug 2004 18:32:34 +0200, Andreas Prilop
<nh******@rrzn-user.uni-hannover.de> wrote:
In what respect is a space more reliable than a tab? And what
about newlines? Don't you have any newlines in your souce text?
Space, tab, newline are equally valid white space.


Crimson Editor, and I'm sure others, allows you to use the tab to indent
your code, and it saves it as spaces instead. You get the time-saving
benefit of the tab key and the more predictable spacing of regular spaces,
both together.
Jul 23 '05 #35

P: n/a
In article <Xn*****************************@193.229.0.31>,
Jukka K. Korpela <jk******@cs.tut.fi> wrote:
Andreas Prilop <nh******@rrzn-user.uni-hannover.de> wrote:
In what respect is a space more reliable than a tab?


A space forwards exactly one character position. A tab may forward to the
next tab stop, and tab stops are set differently in different programs.
This is relevant, since this was about using tabs for formatting HTML
source.


Yes, so if I'm editing the file, I can set my tabstop to the identation
amount that I prefer, then when you edit or view the file, you can set
it to what you prefer. If the tool does not allow you to set tabstops,
get a better tool!

Note that I only use tabs to indent lines, so they at the beginning of
the lines.

--
= Eric K. Bustad
--
= Eric K. Bustad Voice: +1 732 949 6257
CAD Systems Engineering Fax: +1 732 949 7512
Lucent Technologies
Holmdel, NJ, USA
Jul 23 '05 #36

P: n/a
Andrew Graham wrote:
Stephen Poley wrote:
last few days, I decided it was time for a test on the effect of
white-space.

Somehow it just doesn't seem worth it ...

Yup. Optimize those jpegs instead.


And encourage caching, instead of doing the opposite.

--
Brian (remove ".invalid" to email me)
http://www.tsmchughs.com/
Jul 23 '05 #37

P: n/a
CJM wrote:
"Stephen Poley" wrote ...
OK. In a previous configuration I always got 56 (to the nearest K),
so I assumed that was normal.

<choke>I've never had > 45, and usually nearer 40!</choke>


<monty python>Lucky bastard!</monty python> I am, as I write this, on
16.8Kbps (sic). On a good day, I get ~19. (Wow! 19!) Since signing up
with this isp, I've never reached 30. I did, on 2 occasions, reach 28.

--
Brian (remove ".invalid" to email me)
http://www.tsmchughs.com/
Jul 23 '05 #38

P: n/a
Neal <ne*****@yahoo.com> wrote:
Crimson Editor, and I'm sure others, allows you to use the tab to indent
your code, and it saves it as spaces instead. You get the time-saving
benefit of the tab key and the more predictable spacing of regular spaces,
both together.


Wastes bytes though.

Different people like different tab widths, so configuring this in the
user's editor is the right way to do it. One code example, and each
get's to see it with their preferred tab width.

--
Spartanicus
Jul 23 '05 #39

P: n/a
Andrew Graham said the following on 19/08/2004 22:21:
Stephen Poley wrote:
The first page loads in 3 seconds, the second in 8 seconds - both
figures seem to be repeatable. This suggests that if you took a file


Here are two more data points for you, both over 24kbps modem from USA
west coast:

2) wget:
D:\test>timethis wget -q
http://www.xs4all.nl/~sbpoley/webmatters/checklist.html | grep "Elapsed"
TimeThis : Elapsed Time : 00:00:05.107

D:\test>timethis wget -q
http://www.xs4all.nl/~sbpoley/misc/checklist.html | grep "Elapsed"
TimeThis : Elapsed Time : 00:00:15.322


$ time wget -q http://www.xs4all.nl/~sbpoley/webmatters/checklist.html
real 0m0.204s

$ time wget -q http://www.xs4all.nl/~sbpoley/misc/checklist.html
real 0m1.158s

I'm an xs4all user myself and 4 hops away from the xs4all webserver over
an ADSL line (2240/416 Kbit/s (down-/upstream)). Anyway, the ratio seems
to be the same for me on a fast(er) line very near to the server as for
Andrew over a slow(er) line in USA.

--
Regards
Harrie
Jul 23 '05 #40

P: n/a
On Fri, 20 Aug 2004 18:32:34 +0200, Andreas Prilop
<nh******@rrzn-user.uni-hannover.de> wrote:
On Fri, 20 Aug 2004, Jukka K. Korpela wrote:

I don't see why you would use tabs,


Because a tab says more than 1000 spaces - so to speak ;-)
I save lots of space characters for a single tab.


This discussion is moot, please end?

--
Rex
Jul 23 '05 #41

P: n/a
On Thu, 19 Aug 2004 20:55:33 +0100, Spartanicus <me@privacy.net> wrote:
Stephen Poley <sb******************@xs4all.nl> wrote:
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS.

I have never seen that, but I have seen a lot of trolls in my life.
I'd suggest that whitespace and comments are 2 different things.


I'd suggest that it's about time for _all_ of you "youngsters" out here
in this NG to put your back to it and go on to present a decent article
that describes solid results from studies you have made.

all the best...

--
Rex
Jul 23 '05 #42

P: n/a

"Stephen Poley" <sb******************@xs4all.nl> wrote in message
news:0m********************************@4ax.com...
People in these groups, and on web-pages, not infrequently suggest that
it is worthwhile cutting down on white-space and comments in HTML and
CSS in order to reduce loading times. I and others have more than once
doubted this, given the data-compression in the HTTP protocol. Having
seen it suggested again a couple of times in the last few days, I
decided it was time for a test on the effect of white-space.


I think that a far bigger problem, in terms of download times, is in the use
of presentational elements and attributes.[1]
In fact, I was recently charged with helping one of our clients (a large
gov't entity) decrease the file size of their pages. It seems like these
folks have never even heard of CSS. A typical page for them contains 8
nested tables (3-4 deep. I've seen up to 6-deep on their pages with forms)
and all presentation with HTML. NO CSS with exception of typography. Some of
their pages are 100kb+ of HTML alone. With images, they can get to 200kb
fast.
I'm not done with the project, but I'm guessing I can get them into the
15-25kb range and still keep their exact look & feel.
[1] - bigger, as it relates to this NG. The biggest problem, of course, is
images

-Karl
Jul 23 '05 #43

P: n/a
JRS: In article <cg**********@ngspool-d02.news.aol.com>, dated Sun, 22
Aug 2004 08:23:33, seen in news:comp.infosystems.www.authoring.html,
Karl Groves <ka**@NOSPAMkarlcore.com> posted :
In fact, I was recently charged with helping one of our clients (a large
gov't entity) decrease the file size of their pages. It seems like these
folks have never even heard of CSS. A typical page for them contains 8
nested tables (3-4 deep. I've seen up to 6-deep on their pages with forms)
and all presentation with HTML. NO CSS with exception of typography. Some of
their pages are 100kb+ of HTML alone.


What would the size of an approximately 800*600 GIF, PNG, or whatever of
such a page be? I tested with about enough plain text (from a Web page)
to fill a printed page, and that was under 19kB as a GIF. A GIF of
proposed garden changes is here 5-6kB; about and has as much structure
as a Web page needs.

Granted, for some users it will not fill the screen; on the other hand,
all[*] who see it will see it very much as the designer intended.
[*] Well, all with colour screens and sight. The less abled might be
better served with a plain-text version.

--
John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 23 '05 #44

P: n/a
Dr John Stockton wrote:
JRS: In article <cg**********@ngspool-d02.news.aol.com>, dated Sun,
22 Aug 2004 08:23:33, seen in
news:comp.infosystems.www.authoring.html, Karl Groves
<ka**@NOSPAMkarlcore.com> posted :
In fact, I was recently charged with helping one of our clients (a
large gov't entity) decrease the file size of their pages. It seems
like these folks have never even heard of CSS. A typical page for
them contains 8 nested tables (3-4 deep. I've seen up to 6-deep on
their pages with forms) and all presentation with HTML. NO CSS with
exception of typography. Some of their pages are 100kb+ of HTML
alone.


What would the size of an approximately 800*600 GIF, PNG, or whatever
of such a page be? I tested with about enough plain text (from a Web
page) to fill a printed page, and that was under 19kB as a GIF. A
GIF of proposed garden changes is here 5-6kB; about and has as much
structure as a Web page needs.


That idea is... horrible. Sorry.

Jul 23 '05 #45

P: n/a
CJM

"Neal" <ne*****@yahoo.com> wrote in message
news:op**************@news.individual.net...
On Fri, 20 Aug 2004 18:32:34 +0200, Andreas Prilop
<nh******@rrzn-user.uni-hannover.de> wrote:
In what respect is a space more reliable than a tab? And what
about newlines? Don't you have any newlines in your souce text?
Space, tab, newline are equally valid white space.


Crimson Editor, and I'm sure others, allows you to use the tab to indent
your code, and it saves it as spaces instead. You get the time-saving
benefit of the tab key and the more predictable spacing of regular spaces,
both together.


It's ironic that many people in this NG wax lyrical about not imposing their
view onto the client and that you merely suggest a presntation, yet these
same people try to impose a view on developers.

Always use tabs; if they are enabled they will indent the code to the level
desired by the developer. If they are not enabled, they will degrade to a
single space which provides some structuring, but not at the expense of lots
of spaces...

[PS. I think lots of editors these days allows you the option to vary the
Tab indentation and to apply Tabs as spaces...]
Jul 23 '05 #46

This discussion thread is closed

Replies have been disabled for this discussion.