On Thu, Dec 4, 2008 at 11:27 AM, Tim Perrett <[EMAIL PROTECTED]> wrote:

>
> I am indeed talking about lift:surround :)
>
> I see processSurroundAndInclude and what it does, but what i really
> want to do it set the content of the surround dynamically (from a
> layout i'll store in the DB)
>
> How would one go about doing this?


All Lift views are looked up via the LiftRule.viewDispatch.  You can put a
partial function via LiftRules.appendViewDispatch to match your template.
Lift will expect a LiftView which is a trait that can do the RDBMS lookup.


>
>
> Cheers
>
> Tim
>
>
>
> On Dec 4, 7:01 pm, "Derek Chen-Becker" <[EMAIL PROTECTED]> wrote:
> > Are you talking about <lift:surround/> tags? Those are handled in
> > LiftSession.processSurroundAndInclude, line 697. Here's some example code
> > for a utility method from an old app that uses it in some DispatchPFs I
> was
> > running:
> >
> >   def process (xhtml : NodeSeq) : XmlResponse = {
> >     val data = <lift:surround with="default"
> > at="content">{xhtml}</lift:surround>
> >     XmlResponse(<html>{
> > S.session.open_!.processSurroundAndInclude(S.uri,data)}</html>)
> >   }
> >
> > Derek
> >
> > On Thu, Dec 4, 2008 at 12:50 PM, Tim Perrett <[EMAIL PROTECTED]>
> wrote:
> >
> > > Hey guys,
> >
> > > Within lift, I cant seem to find where the content returned from
> > > whatever template mech then gets bound to the layout content?
> >
> > > Can someone point me in the right direction?
> >
> > > Cheers
> >
> > > Tim
> >
>


-- 
Lift, the simply functional web framework http://liftweb.net
Collaborative Task Management http://much4.us
Follow me: http://twitter.com/dpp
Git some: http://github.com/dpp

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to