CWIS Developer Documentation
|
Generator for text input fields. More...
Setup/Initialization | |
TextFormField ($Name, $IsRequired, $Label, $Length, $MaxLength, $ValidFunc=NULL, $ValidMsgs=NULL) | |
Object Constructor. More... | |
Accessors | |
Length ($NewVal=NULL) | |
Get or set the display length for this field. More... | |
MaxLength ($NewVal=NULL) | |
Get or set the maximum input length for this field. More... | |
Display | |
PrintInput ($DisplayErrorIndicator=FALSE) | |
Generate HTML for this object. More... | |
Additional Inherited Members | |
![]() | |
FormField ($Name, $IsRequired, $Label, $ValidFunc, $ValidMsgs) | |
Object Constructor. More... | |
Name ($NewVal=NULL) | |
Get or set the name. More... | |
IsRequired ($NewVal=NULL) | |
Get/set IsRequired. More... | |
Label ($NewVal=NULL) | |
Get or set the form field label as shown to the user. More... | |
Value ($NewVal=NULL) | |
Get or set the form field value. More... | |
IsPassword () | |
Determine if this form field is a password form field. More... | |
PrintField ($DisplayErrorIndicator=FALSE) | |
Print the form field label and generate input tags for this form field. More... | |
PrintLabel ($DisplayErrorIndicator=FALSE) | |
Print the label for this form field without generating the input tags. More... | |
IsInvalidValue ($Value) | |
Check the validity of the form field's value. More... | |
GetInvalidValueMessage ($ErrorCode) | |
Map an error code from IsInvalidValue to an error message. More... | |
![]() | |
$MyName | |
$MyIsRequired | |
$MyLabel | |
$MyValue | |
$MyValidFunc | |
$MyValidMsgs | |
Generator for text input fields.
Definition at line 15 of file TextFormField.php.
TextFormField::Length | ( | $NewVal = NULL | ) |
Get or set the display length for this field.
int | $NewVal | (OPTIONAL) |
Definition at line 53 of file TextFormField.php.
TextFormField::MaxLength | ( | $NewVal = NULL | ) |
Get or set the maximum input length for this field.
int | $NewVal | (OPTIONAL) |
Definition at line 60 of file TextFormField.php.
TextFormField::PrintInput | ( | $DisplayErrorIndicator = FALSE | ) |
Generate HTML for this object.
bool | $DisplayErrorIndicator | (OPTIONAL) |
Definition at line 71 of file TextFormField.php.
TextFormField::TextFormField | ( | $Name, | |
$IsRequired, | |||
$Label, | |||
$Length, | |||
$MaxLength, | |||
$ValidFunc = NULL , |
|||
$ValidMsgs = NULL |
|||
) |
Object Constructor.
string | $Name | internal name for this field, used in html id= |
bool | $IsRequired | whether or not the field is required |
string | $Label | display name for this field, shown to user |
int | $Length | Length of the display box |
int | $MaxLength | The maximum allowed entry size |
callback | $ValidFunc | A function to check this field for valid input (OPTIONAL) |
array | $ValidMsgs | An array of error messages which should correspond to the error codes issued by ValidFunc (OPTIONAL) |
Definition at line 33 of file TextFormField.php.
References FormField\FormField().
Referenced by PasswordFormField\PasswordFormField().