[Lift] Re: bind with outer element?

2009-08-12 Thread jon
Hi, I actually solved by wrapping the node i cared about in another node, but tried the FuncBindParam and it does seem to only grab the child nodes. On Aug 11, 11:37 pm, Naftoli Gugenheim naftoli...@gmail.com wrote: Doesn't the FuncBindParam only get the element's child NodeSeq?

[Lift] Re: bind with outer element?

2009-08-12 Thread Ross Mellgren
BindHelpers.currentNode is a Box[NodeSeq] that gives you the node that bind is currently replacing. -Ross On Aug 12, 2009, at 11:02 AM, jon wrote: Hi, I actually solved by wrapping the node i cared about in another node, but tried the FuncBindParam and it does seem to only grab the

[Lift] Re: bind with outer element?

2009-08-12 Thread jon
Thanks Ross! that works. On Aug 12, 1:59 pm, Ross Mellgren dri...@gmail.com wrote: BindHelpers.currentNode is a Box[NodeSeq] that gives you the node that   bind is currently replacing. -Ross On Aug 12, 2009, at 11:02 AM, jon wrote: Hi, I actually solved by wrapping the node i

[Lift] Re: bind with outer element?

2009-08-12 Thread David Pollak
On Wed, Aug 12, 2009 at 11:31 AM, jon jonhoff...@gmail.com wrote: Thanks Ross! that works. +1 On Aug 12, 1:59 pm, Ross Mellgren dri...@gmail.com wrote: BindHelpers.currentNode is a Box[NodeSeq] that gives you the node that bind is currently replacing. -Ross On Aug 12, 2009,

[Lift] Re: bind with outer element?

2009-08-11 Thread Timothy Perrett
Jon, To read attributes, you do the following: S.attr(shorten) // = Box[String] Cheers, Tim On Aug 10, 9:44 pm, jon jonhoff...@gmail.com wrote: Hi, I have a template with the following lift:Snippit   t:name shorten=true /   t:foo form=POST     form:name/     ...   /t:foo

[Lift] Re: bind with outer element?

2009-08-11 Thread Naftoli Gugenheim
If I'm not mistaken, S.attr is an attribute on the snippet xml node; for the node currently being processed by bind you use BindHelpers.attr - Timothy Perretttimo...@getintheloop.eu wrote: Jon, To read attributes, you do the following: S.attr(shorten) //

[Lift] Re: bind with outer element?

2009-08-11 Thread David Pollak
On Mon, Aug 10, 2009 at 1:44 PM, jon jonhoff...@gmail.com wrote: Hi, I have a template with the following lift:Snippit t:name shorten=true / t:foo form=POST form:name/ ... /t:foo /lift:Snippet And a snippet like: def doSnippet(x:NodeSeq):NodeSeq = { bind(t, x, name-

[Lift] Re: bind with outer element?

2009-08-11 Thread Naftoli Gugenheim
Doesn't the FuncBindParam only get the element's child NodeSeq? - David Pollakfeeder.of.the.be...@gmail.com wrote: On Mon, Aug 10, 2009 at 1:44 PM, jon jonhoff...@gmail.com wrote: Hi, I have a template with the following lift:Snippit t:name