net.liftweb.builtin.snippet

Msg

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

  <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

Linear Supertypes
DispatchSnippet, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Msg
  2. DispatchSnippet
  3. AnyRef
  4. Any
Visibility
  1. Public
  2. All

Type Members

  1. type DispatchIt = PartialFunction[String, (NodeSeq) ⇒ NodeSeq]

    Definition Classes
    DispatchSnippet

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  8. def dispatch: DispatchIt

    Definition Classes
    MsgDispatchSnippet
  9. def effects(id: String): NodeSeq

    This method renders a <script/> element that renders effects for the given id.

    This method renders a <script/> element that renders effects for the given id.

    See also

    net.liftweb.builtin.snippet.Msgs#effects[T](Box[NoticeType.Value],String,T,Box[JsCmd => T])

  10. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  13. final def getClass(): java.lang.Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  16. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  17. final def notify(): Unit

    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  19. def render(styles: NodeSeq): NodeSeq

    This method performs extraction of the CSS class attributes as well as rendering of any messages for the given id.

  20. def renderIdMsgs(id: String): NodeSeq

    This method renders the <span/> for a given id's notices, along with any effects configured for the id.

    This method renders the <span/> for a given id's notices, along with any effects configured for the id.

    See also

    net.liftweb.http.LiftRules#noticesEffects

    ,

    net.liftweb.http.S#error(String,NodeSeq)

    ,

    net.liftweb.http.S#error(String,String)

  21. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  22. def toString(): String

    Definition Classes
    AnyRef → Any
  23. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()
  24. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()
  25. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from DispatchSnippet

Inherited from AnyRef

Inherited from Any