On Wed, Oct 21, 2009 at 6:26 AM, philip <[email protected]> wrote:
>
> Hi,
>
> How can I get a Liftweb menu to be generated from database content?
>
The meditative answer is: functions are first class citizens in Scala. :)
>
> Alternatively, can the menu come from a XML datasource? could I load/
> serialize from that?
> Could it change dynamically at any time?
>
//From Bootstrap
// Build SiteMap
val entries =
Menu(Loc("Home", List("index"), "Home")) ::
Menu(Loc("Create", List("createBusiness"), "Create Business", Hidden))
::
Nil
LiftRules.setSiteMap(SiteMap(entries:_*))
so you could replace any menu entry in the above with a function call that
returns a single, or list of Menu's.
>
> Thanks, Philip
>
>
> >
>
--
James A Barrows
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---