If you want to reuse a snippet with different parameters, you have two options to my knowledge. 1) An attribute on the snippet tag, which can be read with S.attr 2) Put xml data inside a node in the snippet, then bind that node in the snippet using a function from NodeSeq to NodeSeq, which analyzes the contents of the bound node (the current node itself is at BindHelpers.currentNode IIRC) and performs some action, and returns an empty Group. Or you can just analyze the xhtml parameter yourself but you probably want to remove the configuration node so it's easier with bind. The latter is probably not the intended use of bind or snippets, but it works and it's a way to reuse a snippet with complex individual configuration. Or you could define the common snippet behavior in a superclass and write a concrete subclass for each set of configuration. Or in Boot set up a table of configured snippet instances and use one of the above methods so that a DispatchSnippet delegates to an instance from the table. If I'm being unclear just ask. :)
------------------------------------- marius d.<[email protected]> wrote: Something like: <a lift:snippet="Path.build">hi</a> where path is the snippet class and build is the method name. But what is your use case? Br's, Marius On Jul 21, 12:11 pm, José María <[email protected]> wrote: > Hi, > > I suppose that this is something simple, how can I put a value inside > a property in a template? > > Something like: > > <a href="/mypath/<myobject:id></myobject:id>">hi</a> > > Thanks. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~----------~----~----~----~------~----~------~--~---
