package snippet
- Alphabetic
- Public
- All
Type Members
-
case class
AjaxMessageMeta
(title: NodeSeq, cssClasses: Box[String]) extends Product with Serializable
This case class is used to hold formatting data for the notice groups so that AJAX and static notices render consistently.
- abstract class CometFailureException extends SnippetFailureException
- class CometNotFoundException extends CometFailureException
- class CometTimeoutException extends CometFailureException
Value Members
-
object
CSS
extends DispatchSnippet
Display Blueprint CSS headers
- object Children extends DispatchSnippet
- object Comet extends DispatchSnippet with LazyLoggable
-
object
Embed
extends DispatchSnippet
This object implements the logic for the <lift:embed> tag.
This object implements the logic for the <lift:embed> tag. It supports retrieving a template based on the "what" attribute, and any <lift:bind-at> tags contained in the embed tag will be used to replace <lift:bind> tags within the embedded template.
-
object
Form
extends DispatchSnippet
This object is the default handler for the <lift:form> tag, which is used to perform AJAX submission of form contents.
This object is the default handler for the <lift:form> tag, which is used to perform AJAX submission of form contents. If the "onsubmit" attribute is set on this tag, then the contents there will be run prior to the actual AJAX call. If a "postsubmit" attribute is present on the tag, then its contents will be executed after successful submission of the form.
-
object
HTML5
extends DispatchSnippet
Sets the DocType to html5
-
object
Head
extends DispatchSnippet
The 'head' snippet.
The 'head' snippet. Use this snippet to move a chunk of
- object Ignore extends DispatchSnippet
-
object
LazyLoad
extends DispatchSnippet
Enclose your snippet tags on your template with LazyLoad and the snippet will execute on a different thread, which avoids blocking the page render.
-
object
Loc
extends DispatchSnippet
The Loc snippet is used to render localized content.
The Loc snippet is used to render localized content.
Lookup resource with the id specified with the locid attribute. Will also try to use the render method or the snippet body as locid if not specified.
So these are equivalent:
<lift:Loc locid="myid"/> <lift.Loc.myid/> <lift:Loc>myid</lift:Loc>
There's a special case with the "i" method. It will use the text content as the locid, and will replace the child node with the localized content instead of the current element.
This is especially useful together with designer friendly snippet markup:
Some header
If the locid "Some header" for the current locale is e.g "En overskrift", this will render
En overskrift
If the locid is not found, it will just render
Some header
-
object
Menu
extends DispatchSnippet
This built-in snippet can be used to render a menu representing your SiteMap.
This built-in snippet can be used to render a menu representing your SiteMap. There are three main snippet methods that you can use:
- builder - Renders the entire SiteMap, optionally expanding all child menus
- group - Renders the MenuItems corresponding to the specified group.
- item - Renders the specific named MenuItem
More detailed usage of each method is provided below
-
object
Msg
extends DispatchSnippet
This class is a built in snippet that allows rendering only notices (Errors, Warnings, Notices) that are associated with the id provided.
This class is a built in snippet that allows rendering only notices (Errors, Warnings, Notices) that are associated with the id provided. This snippet also renders effects configured for the given id. Typically this will be used near by form fields to indicate that a certain field failed the validation. For example:
<input type="text" value="" name="132746123548765"/><lift:msg id="user_msg"/>
Additionally, you may specify additional CSS classes to be applied to each type of notice using the followin attributes:
- errorClass
- warningClass
- noticeClass
<input type="text" value="" name="132746123548765"/><lift:msg id="user_msg" errorClass="error_class" warningClass="warning_class" noticeClass="notice_class"/>
Notices for specific ids are set via the S.error(String,String) or S.error(String,NodeSeq) methods. Global (non-id) notices are rendered via the Msgs snippet.
- See also
net.liftweb.http.LiftRules#noticesEffects
net.liftweb.http.S#error(String,NodeSeq)
net.liftweb.http.S#error(String,String)
net.liftweb.builtin.snippet.Msgs
-
object
MsgErrorMeta
extends SessionVar[HashMap[String, String]]
This SessionVar holds a map of per-id CSS classes for error notices so that the AJAX and static renderers use the same formatting.
-
object
MsgNoticeMeta
extends SessionVar[HashMap[String, String]]
This SessionVar holds a map of per-id CSS classes for notice notices so that the AJAX and static renderers use the same formatting.
-
object
MsgWarningMeta
extends SessionVar[HashMap[String, String]]
This SessionVar holds a map of per-id CSS classes for warning notices so that the AJAX and static renderers use the same formatting.
-
object
Msgs
extends DispatchSnippet
This built in snippet renders messages (Errors, Warnings, Notices) in a div.
This built in snippet renders messages (Errors, Warnings, Notices) in a div. Typically it is used in templates as a place holder for any messages that are not associated with an ID. Setting the attribute showAll to true will render all messages, with and without an ID. This will lead to duplicate messages if additionally the Msg built in snippet is used to show messages associated with an ID.
E.g. (child nodes are optional)
<lift:Msgs showAll="false"> <lift:error_msg class="errorBox" >Error! The details are:</lift:error_msg> <lift:warning_msg>Whoops, I had a problem:</lift:warning_msg> <lift:warning_class>warningBox</lift:warning_class> <lift:notice_msg>Note:</lift:notice_msg> <lift:notice_class>noticeBox</lift:notice_class> </lift:snippet>
JavaScript fadeout and effects for the three types of notices (Errors, Warnings and Notices) can be configured via LiftRules.noticesAutoFadeOut and LiftRules.noticesEffects. Notices for individual elements based on id can be rendered using the <lift:msg/> tag.
- See also
net.liftweb.http.LiftRules#noticesEffects
net.liftweb.http.LiftRules#noticesAutoFadeOut
net.liftweb.builtin.snippet.Msg
-
object
MsgsErrorMeta
extends SessionVar[Box[AjaxMessageMeta]]
This SessionVar holds formatting data for error notices so that the AJAX and static notice renderers use the same formatting.
-
object
MsgsNoticeMeta
extends SessionVar[Box[AjaxMessageMeta]]
This SessionVar holds formatting data for notice notices so that the AJAX and static notice renderers use the same formatting.
-
object
MsgsWarningMeta
extends SessionVar[Box[AjaxMessageMeta]]
This SessionVar holds formatting data for warning notices so that the AJAX and static notice renderers use the same formatting.
- object NoCometTypeException extends CometFailureException
-
object
ShowAll
extends RequestVar[Boolean]
This SessionVar records whether to show id-based messages in addition to non-id messages.
- object SkipDocType extends DispatchSnippet
- object Surround extends DispatchSnippet
- object Tail extends DispatchSnippet
-
object
TestCond
extends DispatchSnippet
Use this builtin snippet to either show or hide some html based on the user being logged in or not.
- object VersionInfo extends DispatchSnippet
-
object
WithParam
extends DispatchSnippet
Evaluates the body and stores it in the WithParam RequestVar map.
Evaluates the body and stores it in the WithParam RequestVar map. This map is used in builtin.snippet.Surround to bind content to named sections. Note that the WithParam snippet is also mapped to "bind-at"
- object WithParamVar extends RequestVar[Map[String, NodeSeq]]
-
object
WithResourceId
extends DispatchSnippet
Adds a resource id entity for each URI in order to control browser caching.
Adds a resource id entity for each URI in order to control browser caching. The rules of creating "unique" URI's are defined in LiftRules.attachResourceId function.
<lift:with-resource-id> <link ... /> <script ... /> </lift:with-resource-id>
- object XmlGroup extends DispatchSnippet