Aaron wrote:
is there a way to remove all white spaces in the html output? ie. everything
as one line.
Well, Response.Filter is where I'd start:
http://msdn.microsoft.com/library/de...ilterTopic.asp
But I don't know eliminating all whitespace is what you'd do, cuz you'd
have to figure out how to detect if you were inside of a tag (don't want
to just erase all spaces, etc.). You wouldn't strip out whitespace like
that.
But you could strip out things like Tab characters (if this is what you
meant). crlf's I thought were problematic when I tried it for a client
(for their pages), but I can't think of why (I thought it caused
problems in Javascript. As long as every line ends with ; the JS should
still run fine. Unless you use the <!-- // --> wrapper around
scripts, as I don't think this can go all on the same line. Example:
<script language="javas cript">
<!--
alert('hello');
// -->
</script>
--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET