Hi!
I am (for the second time) starting to play with lift (updated to the
newest version). I like the idea of binding with css selectors but I
have a problem figuring out how to do the folowing.
I have this snippet and template:
def list(in: NodeSeq) =
User.findAll.flatMap( user =>bind("user", in, "firstname" ->
user.firstName, "lastname" -> user.lastName) )
<table>
<lift:users.list>
<tr>
<td>
<user:firstname/>
</td>
<td>
<user:lastname/>
</td>
</tr>
</lift:users.list>
</table>
Now I want to change template to the folowing and utilize css
selectors but I have had no luck figuring it out so far. Can anyone
help please?
<table>
<tr class="lift:users">
<td>
<span class="firstname" />
</td>
<td>
<span class="lastname" />
</td>
</tr>
</table>
Thanks!
--
You received this message because you are subscribed to the Google Groups "Lift" group.
To post to this group, send email to lif...@googlegroups.com.
To unsubscribe from this group, send email to liftweb+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en.
On 23 stu, 17:19, Graham Tackley <graham.tack...@guardian.co.uk>
wrote:
> On Nov 23, 3:48 pm, ivan <ivan.se...@gmail.com> wrote:
> Hmm that error message is not saying quite the right thing about theI tried the above (<tr class="lift:users">), i am using lift 2.2-M1.
> required signature - looking at the code in LiftSession a signature of
> (NodeSeq) => NodeSeq is one of a few that are acceptable. But the
> gist is correct, it can't call your method.
>
> render is the default method name that is invoked on a snippet, so
> perhaps that is confusing things. Try changing your template to <tr
> class="lift:users"> and see if that works.
>
> Failing that, what version of lift are you using and can you post your
> full snippet code?
This is the entire error displayed in the browser:
Error processing snippet users.
Reason: Method Not FoundXML causing this error:
There are possible matching methods (render), but none has the
required signature:
def render(in: NodeSeq): NodeSeq
<tr xmlns="http://www.w3.org/1999/xhtml">
<td>
<span class="firstname"></span>
</td>
<td>
<span class="lastname"></span>
</td>
</tr>
--
You received this message because you are subscribed to the Google Groups "Lift" group.
To post to this group, send email to lif...@googlegroups.com.
To unsubscribe from this group, send email to liftweb+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en.
- Mads