Mark Fuller wrote:
If I have something like this for readability in the template:
============================== <TMPL_IF NAME="ERRMSG">
<p>Error: <TMPL_VAR NAME=ERRMSG>
<TMPL_IF NAME="EMAIL_AVAILABLE">
(Forgot your password? <a href="">Reset and email it to yourself</a>.)
</TMPL_IF>
</p>
</TMPL_IF> ================================
The resulting HTML has a lot of newlines.
I'd like to ask if there should'nt be a feature in H::T that would let the template author selectively disable "rendering" linefeeds as meaningful (intended) whitespace? What I am suggesting is an attribute for TMPL_IF (and other operations?) named "NOLF" that would cause H::T to discard linefeeds?
Why should this matter (besides the bandwidth issue)? HTML ignores whitespace
and other than looking at the output of a template every now and then to make
sure that it is what you want, why do you care what the output looks like?
I like the fact that it does exactly what you tell it to do. If you have whitespace it puts it in your loop. If you don't have whitespace it won't. Fairly intuitive to me. Anyone?
Ah, this reminds me of when I had to use ColdFusion, and the code was producing *hundreds* and *hundreds* of lines of whitespace (I think this was a v4.5 issue that was later somewhat 'fixed') Anyway, bandwidth became a huge issue, as the pages were pretty hefty to begin with.
It sounds like a feature that may be useful to some where every kbyte and second really matter.
Pete
-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Html-template-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/html-template-users