wwHtmlHelpers.HtmlLabel

Creates a <label> control as an HTML string.

Example:

lcHtml = HtmlLabel("Name:","txtName",[class="leftlabel"])

which generates:

<label for="txtName" id="txtName_label" class="leftlabel">Name:</label>
o.wwHtmlHelpers.HtmlLabel(lcText,lcFor,lcAttributes,lcId)

Parameters

lcText
The text content of the label

lcFor
Optional: the input control that this label is for. Leave blank to skip

lcAttributes
Any additional attributes to add to the label control

lcId
Optional - ID set for the control. If not specified and lcFor is set the Id will be lcFor + "_label". If both are empty no id is set.

See also

Class wwHtmlHelpers