You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by Andrew Ducker <an...@ducker.org.uk> on 2012/02/13 18:45:39 UTC
Re: Stopping parsing
On 29/01/2012 21:07, Guillaume Polet wrote:
> What about #stop() ?
> http://velocity.apache.org/engine/devel/user-guide.html#Stop
>
> Otherwise, there is also a #parse macro that can help you slice your
> templates into smaller ones and organize a little bit more.
#stop for some reason included bits of text including the # character in
its output, even if they were from after it (and as the page had several
bits of jquery, that wasn't good).
But putting together a page with:
<!DOCTYPE HTML>
#if(!$userdata.loggedIn)
#parse ( "ResetToNotLoggedIn.vm" )
#else
#parse ( "LoggedInMainPage.vm" )
#end
worked perfectly, and is neater than having it all in one file.
Thanks!
Andy
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@velocity.apache.org
For additional commands, e-mail: user-help@velocity.apache.org