On Tue, Mar 2, 2010 at 8:03 AM, Nolan Darilek <[email protected]>wrote:
> Just wondering if anyone had any thoughts on this?
>
> I still can't bind fields in an embedded template. They're returned as is,
> not transformed. Not sure what I'm doing wrong.
If you put up a runable Maven project on GitHub, I'll fix the code to make
it work for you.
>
>
> On 02/23/2010 11:33 AM, Nolan Darilek wrote:
>
>> Cool, thanks for all your help here. It's been quite a bit to digest, and
>> I finally got around to revisiting this problem today.
>>
>> So I'm not sure why my initial attempts to return a <lift:embed> from the
>> render method failed, but today that seems to work. Need to see if Firefox
>> is doing anything odd with caching, because I seem to have lots of odd
>> problems of this sort. In the meantime, I'll poke at things with Curl before
>> claiming that they don't work.
>>
>> I'm trying to create a cleaner design based on returning lift:embed, but
>> I'm still having problems, even after Curl. :) Here's what I have thus far.
>>
>> My status.html:
>>
>> <lift:surround with="default" at="content">
>>
>> <h2>Imports</h2>
>>
>> <lift:comet type="ImportMonitor"/>
>> </lift:surround>
>>
>> templateshidden/importing.html, returned by comet render:
>>
>> <table>
>> <tr>
>> <th>Name</th><th>Complete</th><th>Total</th><th>Status</th>
>> </tr>
>> <tr>
>> <td><import:name/></td>
>> </tr>
>> </table>
>>
>> And part of my ImportMonitor code:
>>
>> class ImportMonitor extends CometActor {
>> ...
>> def render = {
>> if(importsCount == 0)
>> <p>No imports are currently in progress.</p>
>> else {
>> bind("import", <lift:embed what="importing"/>,
>> "name" -> "Name"
>> )
>> }
>> }
>>
>> ...
>> }
>>
>> I've tried a variety of things at that bind call. What it ultimately does
>> is returns my template as is, including the <import:name></import:name>. I
>> also tried eager_eval="true" on the embed element, but with no luck.
>>
>> Thoughts on what I'm missing? I feel like binding keeps tripping me up. I
>> understand the concept, in essence, but it seems like this should work to me
>> and I don't see why it isn't.
>>
>> Thanks for being such a newbie-friendly community.
>>
>>
>
> --
> 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]<liftweb%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/liftweb?hl=en.
>
>
--
Lift, the simply functional web framework http://liftweb.net
Beginning Scala http://www.apress.com/book/view/1430219890
Follow me: http://twitter.com/dpp
Surf the harmonics
--
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.