contenido\classes\class.form.php

Show: PublicProtectedPrivateinherited
Table of Contents
Project: Contenido Content Management System

Description: Class for creating form pages

Requirements:

Author
Jan Lengowski  
Con_php_req
5.0  
Copyright
four for business AG  
License
http://www.contenido.org/license/LIZENZ.txt  
Link
http://www.4fb.de  
Link
http://www.contenido.org  
Package
Contenido Backend classes  
Since
file available since contenido release <= 4.6 {@internal created unknown modified 2008-06-30, Dominik Ziegler, add security fix modified 2009-10-23, Murat Purc, removed deprecated function (PHP 5.3 ready) $Id: class.form.php 1085 2009-10-24 02:01:34Z xmurrix $: }}  
Version
1.0.1  

\Form

Package: Default

Properties

>VPropertypublicstring $action = ''
action
Default value''Details
Type
string
>VPropertypublicint $counter = 0
counter
Default value0Details
Type
int
>VPropertypublicbool $debug = false
debug
Default valuefalseDetails
Type
bool
>VPropertypublicarray $default = array()
defaults
Default valuearray()Details
Type
array
>VPropertypublicstring $enctype = ''
enctype
Default value''Details
Type
string
>VPropertypublicarray $fields = array()
fields
Default valuearray()Details
Type
array
>VPropertypublicbool $isSend = false
isSend
Default valuefalseDetails
Type
bool
>VPropertypublicstring $method = 'post'
method
Default value'post'Details
Type
string
>VPropertypublicbool $passed = false
passed
Default valuefalseDetails
Type
bool
>VPropertypublicstring $target = '_self'
target
Default value'_self'Details
Type
string

Methods

methodpublicAdd( $name) : void

Add() Add a form element

Parameters
NameTypeDescription
$name
methodpublicCheckFormValues() : void

CheckFormValues()

methodpublicDefine( $which,  $value) : void

Define() Define properties of the form or the elements

Parameters
NameTypeDescription
$which
$value
Details
string

Which property to define

string

Values of the property

methodpublicForm() : void

Constructor Function

methodpublicGenerate( $template) : void

Form::generate()

Parameters
NameTypeDescription
$template

string Path/Filename of the template to use

methodpublicGetFormValues() : void

GetFormValues() Extract the Form Data from the $_POST or $_GET global arrays

methodpublicPassed() : bool

Passed() Checks if the form passed

Returns
TypeDescription
boolTRUE: Form passed without errors, FALSE: Errors
methodpublicSetDefault( $name,  $value) : void

SetDefault() Add a default value

Parameters
NameTypeDescription
$name
$value

\FormCheck

Package: Default
class FormCheck Class for checking form values
Author
Jan Lengowski  
Copyright
four for business 2002  
Version
1.0  

Methods

methodpublicFormCheck() : void

Constructor function

Details
Access
private  
methodpublicisAlphabetic( $value) : void

isAlphabetic() Checks if a value is alphabetic

Parameters
NameTypeDescription
$value

mixed Value to check

methodpublicisEmail( $value) : void

isEmail() Checks if a string is a valid email adress

Parameters
NameTypeDescription
$value

string eMail string to check

methodpublicisNotEmpty( $value) : void

isNotEmpty() Checks if a value is NOT empty

Parameters
NameTypeDescription
$value

mixed Value to check

methodpublicisNotNull( $value) : void

isNotNull() Checks if a value is NOT null

Parameters
NameTypeDescription
$value

mixed Value to check

methodpublicisNumeric( $value) : void

isNumeric() Checks if a value is numeric

Parameters
NameTypeDescription
$value

mixed Value to check

\FormField

Package: Default
Class Formfield Class for creating form elements
Author
Jan Lengowski  
Copyright
four for business 2002  
Version
1.0  

Methods

methodpublicFormField() : void

Constructor Function

methodpublicGenerateCode( $item) : void

Function GenerateCode() Created HTML Code depending on the type of form field selected.

Parameters
NameTypeDescription
$item
Details
Argument
$item array All necessary formfield data  
Documentation was generated by phpDocumentor 2.0.0a12.