Priority: Enhancement
Current State: Closed
Released In: 1.1.0
Target Release: minor
Applies To: Engine
Component:
Branches:
to remove the tmpl ASSERT and make it possible to send out valid html
--
SvenDowideit - 24 May 2010
plain and default skins are dying now on ordinary view
I don't understand. There's a newline being added after
bodyend
, and I can't tell why. I especially don't know why it's not affecting
PatternSkin. A hexdump of a sampling of the
.tmpl
files shows 0x0a at the end of all of them (to be expected).
So far the only work-around I have is to put a \ as the final character in the
view.tmpl
and
view.plain.tmpl
, but that doesn't really help.
--
PaulHarvey - 24 May 2010
oh, thankyou, that helps a heck of a lot, until
SimplifyMasterTemplateDefinition is done
--
SvenDowideit - 24 May 2010
Just sharing observation, but maybe it was an obvious observation?
--
PaulHarvey - 24 May 2010
maybe it was
obvious, but I didn't think of it! and now that you've mentioned it, I'm going to use it, cos as I say, it helps.
sadly, it looks to me like much of the problem is that TMPL:INCLUDEing
foswiki
at the top of a tmpl file means that subsequent empty lines go on the end, what a mess.
interestingly, removing
some newlines makes the problem worse (groan)
much later....
I think I've found a much more sane fix - add a TMPL:DEF after the literal fallthrough definition, and things see to get much better.
I have also added a regex to remove newlines after a TMPL comment, and those can lead to the same issue.
--
SvenDowideit - 24 May 2010
the change that should go into the release note is that we now remove newlines and whitespace before and after both TMPL:END and TMPL comments
Doesn't the regex to remove newlines after a TMPL comment change the spec, and therefore require a documentation update? I'm OK with it, BTW, but think it should be symmetric (remove whitespace after
and before %{...}% )
--
CrawfordCurrie - 25 May 2010
cool - I didn't quite have the guts to remove before - but i do prefer it - and thanks for the docs.
--
SvenDowideit - 07 Jun 2010