Class TFormTextIntDouble

Description

Two text fields that only accept numbers.

Stored in the database in a string, using a special seperator to seperate the two values.

  • version: 03-08-2002 12:00
  • author: Greg MacLellan

Located in /form-text-int-double.inc.php (line 14)

TFormElement
   |
   --TFormText
      |
      --TFormTextIntDouble
Variable Summary
mixed $format
mixed $maxdec
mixed $maxval
mixed $minval
mixed $seperator
Method Summary
TFormTextIntDouble TFormTextIntDouble (string $name, string $displayname, string $class, bool $required, int $size, bool $format, string $seperator, [int $min = null], [int $max = null], [int $maxdec = null], [string $value = ""], [bool $store = true])
A getValue ([$display $display = false])
void output ()
true setValue (mixed $value, bool $user)
void validate ()
Variables
mixed $format (line 18)
mixed $maxdec (line 17)
mixed $maxval (line 16)
mixed $minval (line 15)
mixed $seperator (line 19)

Inherited Variables

Inherited from TFormText

TFormText::$htmltype
TFormText::$maxsize
TFormText::$regex
TFormText::$required
TFormText::$size
TFormText::$type

Inherited from TFormElement

TFormElement::$alwaysSet
TFormElement::$class
TFormElement::$displayname
TFormElement::$name
TFormElement::$parent
TFormElement::$store
TFormElement::$value
Methods
Constructor TFormTextIntDouble (line 43)

Creates a new TFormTextIntDouble element (two integer input fields).

TFormTextIntDouble TFormTextIntDouble (string $name, string $displayname, string $class, bool $required, int $size, bool $format, string $seperator, [int $min = null], [int $max = null], [int $maxdec = null], [string $value = ""], [bool $store = true])
  • string $name: The name of the element. This should correspond to the field names if using with TDBForm, and should not include any spaces or special characters.
  • string $displayname: The name that should show up to the user for this field.
  • string $class: The HTML Class to use for the element
  • bool $required: True if the field has to be filled in
  • int $size: The displayed size of the text box
  • bool $format: True to format the value using comma seperators
  • string $seperator: String to seperate the two values in the database.
  • int $min: The minimum value, or null if no minimum
  • int $max: The maximum value, or null if no maximum
  • int $maxdec: Maximum number of decimal places, null if no maximum
  • string $value: The initial value for the field. Note if using a TDBForm this value will be overridden by loadValues so it is effectively only the default for new entries.
  • bool $store: Whether this value is persistent. Used by TDBForm to decide to save/load this value from database.
getValue (line 131)

Returns a textual description of the current value

  • return: string containing the value of the element
A getValue ([$display $display = false])
  • $display $display: True if the value is going to be used for display

Redefinition of:
TFormElement::getValue()
Returns a textual description of the current value
output (line 135)
void output ()

Redefinition of:
TFormText::output()
setValue (line 115)

Sets the value of the field

  • return: if the value was set
true setValue (mixed $value, bool $user)
  • mixed $value: The value to set
  • bool $user: True if the value is from user input

Redefinition of:
TFormElement::setValue()
Sets the value of the field
validate (line 54)
void validate ()

Redefinition of:
TFormText::validate()

Inherited Methods

Inherited From TFormText

TFormText::TFormText()
TFormText::output()
TFormText::setRegex()
TFormText::validate()

Inherited From TFormElement

TFormElement::TFormElement()
TFormElement::getValue()
TFormElement::output()
TFormElement::setParent()
TFormElement::setValue()
TFormElement::validate()

Documentation generated on Thu, 27 Nov 2003 14:58:58 -0500 by phpDocumentor 1.2.3