Overview

Packages

  • CONTENIDO
  • Core
    • Authentication
    • Backend
    • Cache
    • CEC
    • Chain
    • ContentType
    • Database
    • Debug
    • Exception
    • Frontend
      • Search
      • URI
      • Util
    • GenericDB
      • Model
    • GUI
      • HTML
    • I18N
    • LayoutHandler
    • Log
    • Security
    • Session
    • Util
    • Validation
    • Versioning
    • XML
  • Module
    • ContentRssCreator
    • ContentSitemapHtml
    • ContentSitemapXml
    • ContentUserForum
    • NavigationTop
    • ScriptCookieDirective
  • mpAutoloaderClassMap
  • None
  • Plugin
    • ContentAllocation
    • CronjobOverview
    • FormAssistant
    • FrontendLogic
    • FrontendUsers
    • Linkchecker
    • ModRewrite
    • Newsletter
    • Repository
      • FrontendNavigation
      • KeywordDensity
    • SearchSolr
    • SmartyWrapper
    • UrlShortener
    • UserForum
    • Workflow
  • PluginManager
  • Setup
    • Form
    • GUI
    • Helper
      • Environment
      • Filesystem
      • MySQL
      • PHP
    • UpgradeJob
  • Smarty
    • Cacher
    • Compiler
    • Config
    • Debug
    • PluginsBlock
    • PluginsFilter
    • PluginsFunction
    • PluginsInternal
    • PluginsModifier
    • PluginsModifierCompiler
    • PluginsShared
    • Security
    • Template
    • TemplateResources
  • Swift
    • ByteStream
    • CharacterStream
    • Encoder
    • Events
    • KeyCache
    • Mailer
    • Mime
    • Plugins
    • Transport

Classes

  • cContentTypePifaForm
  • DefaultFormModule
  • DefaultFormProcessor
  • ExampleOptionsDatasource
  • MailedFormProcessor
  • Pifa
  • PifaAbstractFormModule
  • PifaAbstractFormProcessor
  • PifaAjaxHandler
  • PifaExporter
  • PifaExternalOptionsDatasourceInterface
  • PifaField
  • PifaFieldCollection
  • PifaForm
  • PifaFormCollection
  • PifaImporter
  • PifaLeftBottomPage
  • PifaRightBottomFormDataPage
  • PifaRightBottomFormExportPage
  • PifaRightBottomFormFieldsPage
  • PifaRightBottomFormImportPage
  • PifaRightBottomFormPage
  • SolrRightBottomPage

Interfaces

  • PifaDatabaseException
  • PifaException
  • PifaIllegalStateException
  • PifaMailException
  • PifaNotImplementedException
  • PifaNotYetStoredException
  • PifaValidationException
  • Overview
  • Package
  • Class
  • Todo
  • Download

Class PifaField

PIFA field item class. It's a kind of a model.

cGenericDb
Extended by cItemBaseAbstract
Extended by Item
Extended by PifaField
Package: Plugin\FormAssistant
Copyright: four for business AG
Author: marcus.gnass
Located at plugins/form_assistant/classes/class.pifa.field.php
Methods summary
public
# __construct( mixed $id = false )

Create an instance.

Create an instance.

Parameters

$id
ID of item to be loaded or false

Throws

cInvalidArgumentException
If table name or primary key is not set

Overrides

Item::__construct()
public mixed
# getField( string $field, boolean $bSafe = true )

Rule has to be stripslashed to allow regular expressions with backslashes.

Rule has to be stripslashed to allow regular expressions with backslashes.

Parameters

$field
$sField Specifies the field to retrieve
$bSafe
Flag to run defined outFilter on passed value

Returns

mixed
Value of the field

See

Item::getField()

Overrides

Item::getField()
public
# getLastError( )

Getter for protected prop.

Getter for protected prop.

public mixed
# getValue( )

Returns this fields stored value.

Returns this fields stored value.

Returns

mixed
the $_value
public
# setValue( mixed $value )

Parameters

$value
$_value
public array
# getFile( )

keys: name, tmp_name

keys: name, tmp_name

Returns

array
the $_file
public
# setFile( array $_file )

Parameters

$_file
public
# validate( )

Throws

PifaValidationException
if an error occured
public string
# toHtml( array $errors = NULL )

Returns HTML for this form that should be displayed in frontend.

Returns HTML for this form that should be displayed in frontend.

Parameters

$errors
to be displayed for form field

Returns

string
public cHTMLLabel
# _getElemLabel( )

Returns

cHTMLLabel

Todo

should be private, right?
public cHTMLTextbox
# _getElemField( boolean $error,… )

Creates the HTML for a form field.

Creates the HTML for a form field.

The displayed value of a form field can be set via a GET param whose name has to be the fields column name which is set if the form is displayed for the first time and user hasn't entered another value.

Parameters

$error,…
if field elem should be displayed as erroneous

Returns

cHTMLTextbox

cHTMLTextarea cHTMLPasswordbox cHTMLSpan cHTMLSelectElement NULL cHTMLButton

Throws

PifaNotImplementedException
if field type is not implemented

Todo

should be private, right?
public Ambigous
# _getElemHelp( )

Returns

Ambigous
<NULL, cHTMLParagraph>

Todo

should be private, right?
public Ambigous
# _getElemScript( )

Returns

Ambigous
<NULL, cHTMLScript>

Todo

should be private, right?
public static array
# getFieldTypeIds( )

Returns an array containing all field type ids.

Returns an array containing all field type ids.

Returns

array
public static array
# getFieldTypeNames( )

Returns an array containing all field type ids mapped to their names.

Returns an array containing all field type ids mapped to their names.

The order of field types in this array influences the order of icons displayed in the backend for selection!

Returns

array
public static string
# getFieldTypeName( integer $fieldTypeId )

Return the field type name for the given field type id.

Return the field type name for the given field type id.

Parameters

$fieldTypeId
$fieldType

Returns

string
public string
# getMyFieldTypeName( integer $fieldType,… )

Return this fields type name.

Return this fields type name.

Parameters

$fieldType,…

Returns

string
public
# getDbDataType( )

Returns a string describing this fields database data type as used in MySQL CREATE and ALTER TABLE statements.

Returns a string describing this fields database data type as used in MySQL CREATE and ALTER TABLE statements.

Throws

PifaException
if field is not loaded
PifaException
if field type is not implemented
public
# delete( )

Deletes this form with all its fields and stored data. The forms data table is also dropped.

Deletes this form with all its fields and stored data. The forms data table is also dropped.

public
# showField( string $columnName )

Determines for which form field types which data should be editable in backend.

Determines for which form field types which data should be editable in backend.

Parameters

$columnName
for data to edit
public array
# getOptions( )

Returns

array
Methods inherited from Item
_inFilter(), _loadByWhereClause(), _onLoad(), _resetItem(), _setMetaObject(), deleteProperty(), deletePropertyById(), get(), getMetaObject(), getProperty(), isLoaded(), loadBy(), loadByMany(), loadByPrimaryKey(), loadByRecordSet(), outFilter(), set(), setField(), setFilters(), setProperty(), store(), toArray(), toObject()
Methods inherited from cItemBaseAbstract
_getPropertiesCollectionInstance(), _getSecondDBInstance(), escape()
Methods inherited from cGenericDb
_executeCallbacks(), register(), unregister()
Constants summary
integer VARCHAR_SIZE

Size to use for VARCHAR fields. Remember: the maximum row size for the used table type, not counting BLOBs, is 65535.

Size to use for VARCHAR fields. Remember: the maximum row size for the used table type, not counting BLOBs, is 65535.

Todo

PIFA should be able to calculate the size for one record by the size of its fields and handle it accordingly.


# 255
integer INPUTTEXT

Input field for single-line text.

Input field for single-line text.

# 1
integer TEXTAREA

Input field for multi-line text.

Input field for multi-line text.

# 2
integer INPUTPASSWORD

Input field for single-line password.

Input field for single-line password.

# 3
integer INPUTRADIO

Radiobox.

Radiobox.

# 4
integer INPUTCHECKBOX

Checkbox

Checkbox

# 5
integer SELECT

Selectbox allowing for selection of a single option.

Selectbox allowing for selection of a single option.

# 6
integer SELECTMULTI

Selectbox allowing for selection of multiple options.

Selectbox allowing for selection of multiple options.

# 7
integer DATEPICKER

Input field for date selection.

Input field for date selection.

# 8
integer INPUTFILE

Input field for file selection.

Input field for file selection.

# 9
integer PROCESSBAR

Processbar.

Processbar.

# 10
integer SLIDER

Slider.

Slider.

# 11
integer BUTTONSUBMIT

Button of type submit.

Button of type submit.

# 13
integer BUTTONRESET

Button of type reset.

Button of type reset.

# 14
integer BUTTON

General button.

General button.

# 15
integer MATRIX
# 16
integer PARA

A text to be displayed between form fields. It's no form field on its own but should be handled like one.

A text to be displayed between form fields. It's no form field on its own but should be handled like one.

# 17
integer INPUTHIDDEN

A hidden input field.

A hidden input field.

# 18
integer FIELDSET_BEGIN

Begin of a fieldset.

Begin of a fieldset.

# 19
integer FIELDSET_END

End of a fieldset.

End of a fieldset.

# 20
integer BUTTONIMAGE

Button of type image (which is in fact a submit button).

Button of type image (which is in fact a submit button).

# 21
Constants inherited from cGenericDb
CREATE_BEFORE, CREATE_FAILURE, CREATE_SUCCESS, DELETE_BEFORE, DELETE_FAILURE, DELETE_SUCCESS, STORE_BEFORE, STORE_FAILURE, STORE_SUCCESS
Properties summary
private mixed $_value

The form fields value.

The form fields value.

# NULL
private array $_file

The file that was transmitted in case of INPUTFILE.

The file that was transmitted in case of INPUTFILE.

# NULL
Properties inherited from Item
$_arrInFilters, $_arrOutFilters, $_lastSQL, $_metaObject, $modifiedValues, $oldPrimaryKey, $values
Properties inherited from cItemBaseAbstract
$_className, $_oCache, $_settings, $db, $lasterror, $primaryKey, $properties, $secondDb, $table, $virgin
CMS CONTENIDO 4.9.7 API documentation generated by ApiGen