(Quick Reference)

attribute

Purpose

It defines a attribute of the enclosing element. The content of the element is the attribute value, while the name attribute specifies the attribute name.

Examples

<z:button label="Hi">
  <z:attribute name="onClick">alert("Hi")</z:attribute>
</z:button>

It is equivalent to

<z:button label="Hi" onClick="alert('Hi')"/>

Description

It is useful if the value of an attribute is sophisticated.