SourceForge.net Logo
Home | SourceForge | Documentation | FAQ | What's New | To-Do List | Forums | Download | Contact

sqlerror Tag

Attribute List:

By default, the error message will be displayed just above the field which generated it. Using this tag allows you to specify where the error messages should go for each individual field. It will be ignored for "display" templates. This must go inside the sqlrow tag.

Note that the only messages that will be displayed here are the ones indicated by constraints on the sqlfield (i.e. the constraints, numeric, max, min, and required attributes). SQL errors that occur will not be displayed here; instead, use sqlrowerror.

Type of tag: Self-closing

Attributes

name


Required: Yes
Values: A valid column name (see sqlfield).

Indicates which column to associate the error message with. There can be only one sqlerror tag with a given name.

startMarkup


Required: No
Values: Any HTML markup

This allows you to put markup before the error; the markup will not be displayed if the error isn't displayed, but will be displayed if the error is displayed. You can use this to e.g. enclose the error in a separate row, which would not appear if the error didn't:

<sqlerror name="field1" startMarkup="<tr><td colspan='4'>" endMarkup="</td></tr>" />

endMarkup


Required: No
Values: Any HTML markup

If given, the value of this attribute will be displayed after the error if the error is displayed (and will not be displayed if the error is not displayed). See startMarkup.

class


Required: No
Values: CSS class

Works like any other class attribute.

style


Required: No
Values: CSS style

Works like any other style attribute.