mandag 29. mars 2010

Adding scripts to CometActor in Lift

If you ever wondered how to include javascript in the head section or how to include other content in the body when using a CometActor the solution is to override fixedRender:



The resulting html:



Notice that Lift is using two div's, and during a reRender(false) only the inner one is updated.


Unfortunately the Alert doesn't take a JsCmd, I would prefer writing:


Ingen kommentarer:

Legg inn en kommentar