OK let me think about it and make a patch. In the meantime can you file a bug for the problems with bricks templates? I would like to fix those too!
Thanks,Dhanji.
On Fri, Jan 21, 2011 at 8:52 PM, Bogdan Sulima <bogdan...@gmail.com> wrote:
I have tried Bricks templating.I have faced some scoping problems with nested Repeat tags and some HTML tag removal due to JSoup parser so i decided to use plain MVEL.
Currently i duplicate a lot of code in my templates so it would be really great to have a possibility to use @include.
the outer loop from the inner one. NoSuchMethod exception was thrown.
Also all javascript tags following HTML tag have been removed and STYLES block from the HEAD was also removed (despite the resolved bug).
CompiledIncludeNode.readInFile(File) also does some pushing and popping
of directories to a stack that seems to be a no-op? Also, a byte buffer
of 10 bytes seems to be a little stingy!
I have mvel 2.0.16
What special setup do I need to do to use MVEL orb tags in my site? I too wanted to use @include to add headers and footers, but I've been unable to use any tags with @ instead of $. I feel like there must be some setup I'm missing, but I don't see anything special in MvelTemplateExample.java in the acceptance tests. If I include something like @{message} it just gets rendered out to the browser.I'm using sitemesh for my layout, but I'd like to stick to one tool for all layout. Is there a better way to create "master pages"?
What special setup do I need to do to use MVEL orb tags in my site? I too wanted to use @include to add headers and footers, but I've been unable to use any tags with @ instead of $. I feel like there must be some setup I'm missing, but I don't see anything special in MvelTemplateExample.java in the acceptance tests. If I include something like @{message} it just gets rendered out to the browser.
org.mvel2.templates.TemplateError: cannot include template '.\Footer.txt': file not found.
at org.mvel2.templates.res.CompiledIncludeNode.readInFile(CompiledIncludeNode.java:115) ~[mvel2-2.1.3.Final.jar:?]
at org.mvel2.templates.res.CompiledIncludeNode.readFile(CompiledIncludeNode.java:78) ~[mvel2-2.1.3.Final.jar:?]
My Code is
Dear @{FIRST_NAME},
Hello How are you??
@include('./Footer.txt')
where Footer.txt contains a sample data
Thanks
Satish
but its throwing the exception as file not found