FORMfields


FORMfields.fields.TimestampField

Class TimestampField

FormField
|
+--DateTimeField
|
+--TimestampField

public class TimestampField
extends DateTimeField

TimestampField is hidden field that automatically captures the timestamp of when the user last submitted the form data.

Since:
FORMfields v3.0

Field Summary
mixed

$dateFormat

The date format used when displaying value of this date to the user.

Fields inherited from FORMfields.fields.DateTimeField
date, dateFormat, endDateTimeString, startDateTimeString, subFieldSeparator, subFieldValueSeparator, time
Fields inherited from FORMfields.fields.FormField
autoPropagate, data, disableEnterHandler, displayValuesOnNewLine, editable, enabled, endingString, enterTabHandler, enterTabs, error, extraHtml, fieldBelowLabel, formError, help, hidden, htmlify, id, isData, label, labelForId, multiValues, name, required, subFieldDisplayValueSeparator, subFieldSeparator, subFieldValueSeparator, subFields, subFieldsCannotBeEmpty, trimWhitespace, validators, value, valueIsHtml
Constructor Summary

TimestampField(string label)

Creates a new TimestampField.

__construct(string label)

Creates a new TimestampField.

Method Summary
void

getParameter()

Sets the value of this field to the current date and time.

Methods inherited from FORMfields.fields.DateTimeField
getCurrentDateTime, getDisplayValue, getUnixTimestamp, isValid, setToCurrentDateTime, setValue
Methods inherited from FORMfields.fields.FormField
addFieldValidator, addSubField, checkForBlank, clearValue, disable, formatRequestParameter, formatText, getButtonClicked, getData, getDbValue, getDisableFieldJs, getDisableJs, getDisableLabelJs, getDisplayFieldTag, getDisplayHtmlValue, getDisplayLabelTag, getDisplayValue, getEditable, getEditableFieldTag, getEditableLabelTag, getEnabled, getError, getExtraHtml, getFieldTag, getFormError, getHelp, getHelpTag, getHidden, getHiddenFieldTag, getId, getIsData, getIsHidden, getLabel, getLabelHtml, getLabelTag, getName, getOrNull, getParameter, getRawDbValue, getRequired, getValue, isBlank, isEmpty, isValid, setAutoPropagate, setData, setDbValue, setDisplayValuesOnNewLine, setEditable, setEnabled, setEndingString, setError, setExtraHtml, setFieldBelowLabel, setFormError, setHelp, setHidden, setHtmlify, setId, setIsData, setIsHidden, setLabel, setName, setRequired, setTrimWhitespace, setValue, setValueIsHtml, validate

Field Detail

dateFormat

public mixed $dateFormat = "Y-n-j g:i A"

The date format used when displaying value of this date to the user. See PHP's date function for all the supported formats.

Since:
FORMfields v3.0

Constructor Detail

TimestampField

public TimestampField(string label)

Creates a new TimestampField.

Parameters:
label - this form field's label. Defaulted to "Timestamp".
Since:
FORMfields v3.0
Deprecated:
deprecated as this constructor syntax is not expected in PHP 5 - will be removed once PHP 5 becomes a minimum requirement for FORMfields

__construct

public __construct(string label)

Creates a new TimestampField.

Parameters:
label - this form field's label. Defaulted to "Timestamp".
Since:
FORMfields v3.0

Method Detail

getParameter

public void getParameter()

Sets the value of this field to the current date and time.

Since:
FORMfields v1.0

FORMfields