Re: How can we pass OGNL list to macro

Daniel Dekany <[email protected]>
Newsgroups gmane.comp.web.freemarker.user
Message-ID <[email protected]>
Certainly it's better to ask the Struts 2 guys about this...
FreeMarker itself doesn't know OGNL.

Wednesday, July 8, 2009, 10:05:48 AM, spsarolkar wrote:

> I am developing website using struts2 and freemarker .
> I want to pass list created using
> ognl({'item1','item2','item3',...}) to
> macro.
> I tried following
> <#macro traverseList mylist>
> //
> </#macro>
> <traverseList mylist="%{'item1','item2',...}" ></traverseList>
> but getting error as 'unexpected collection or sequence..//..'
> Following works
> <traverseList mylist=['item1','item2',...] ></traverseList>
> But i want it through ognl because i want to pass expression like
> collectionName{expression} e.g. users.{?#this.age>20}

-- 
Best regards,
 Daniel Dekany


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.