[ Index ] |
|
Code source de eGroupWare 1.2.106-2 |
[Code source] [Imprimer] [Statistiques]
Base plugin class.
Poids: | 1596 lignes (37 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
Classe: Savant2_Plugin_form - X-Ref
Creates XHTML forms with CSS and table-based layouts.plugin($method) X-Ref |
Central switcher API for the the various public methods. param: string $method The public method to call from this class; all return: string XHTML generated by the public method. |
set($key, $val) X-Ref |
Sets the value of a public property. param: string $key The name of the property to set. param: mixed $val The new value for the property. return: void |
start($attr = null) X-Ref |
Starts the form. The form defaults to 'action="$_SERVER['REQUEST_URI']"' and 'method="post"', but you can override those, and add any other attributes you like. param: array|string $attr Attributes to add to the form tag. return: A <form> tag. |
end() X-Ref |
Ends the form and closes any existing layout. return: The ending layout XHTML and a </form> tag. |
button($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'button' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
checkbox($name, $value = null, $label = null, $options = null,$attr = null, $validCode = null, $validMsg = null) X-Ref |
Generates a 'checkbox' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: mixed $options If a scalar (single value), then value of the param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
file($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'file' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
hidden($name, $value = null, $attr = null) X-Ref |
Generates a 'hidden' element (no layout is generated). param: string $name The element name. param: mixed $value The element value. param: array|string $attr Attributes for the element tag. return: string The element XHTML. |
image($name, $src, $label = null, $attr = null, $validCode = null,$validMsg = null) X-Ref |
Generates an 'image' element. param: string $name The element name. param: mixed $src The image HREF source. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
password($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'password' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
radio($name, $value = null, $label = null, $options = null,$attr = null, $validCode = null, $validMsg = null) X-Ref |
Generates a set of radio button elements. param: string $name The element name. param: mixed $value The radio value to mark as 'checked'. param: string $label The element label. param: array $options An array of key-value pairs where the array param: array|string $attr Attributes added to each radio. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The radio buttons XHTML. |
reset($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'reset' button. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
select($name, $value = null, $label = null, $options = null,$attr = null, $validCode = null, $validMsg = null) X-Ref |
Generates 'select' list of options. param: string $name The element name. param: mixed $value The option value to mark as 'selected'; if an param: string $label The element label. param: array $options An array of key-value pairs where the array param: array|string $attr Attributes added to the 'select' tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The select tag and options XHTML. |
submit($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'submit' button. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
note($text, $label = null, $validCode = null, $validMsg = null) X-Ref |
Adds a note to the form. param: string $text The note text. param: string $label The label, if any, for the note. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
text($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'text' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
textarea($name, $value = null, $label = null, $attr = null,$validCode = null, $validMsg = null) X-Ref |
Generates a 'textarea' element. param: string $name The element name. param: mixed $value The element value. param: string $label The element label. param: array|string $attr Attributes for the element tag. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element XHTML. |
block($action = 'start', $label = null, $type = 'col', $float = null, $clear = null) X-Ref |
Builds XHTML to start, end, or split layout blocks. param: string $action Whether to 'start', 'split', or 'end' a block. param: string $label The fieldset legend. If an empty string, param: string $type The layout type to use, 'col' or 'row'. The param: string $float Whether the block should float 'left' or param: string $float Whether the block should be cleared of 'left' return: string The appropriate XHTML for the block action. |
group($type, $label = null) X-Ref |
Builds the layout for a group of elements; auto-starts a block if needed. param: string $type Whether to 'start' or 'end' the group. param: string $label The label for the group. return: string The element-group layout XHTML. |
_attr($attr = null) X-Ref |
Builds an attribute string for a tag. param: array|string $attr The attributes to add to a tag; if an array, return: string A string of tag attributes. |
_tag($type, $attr = null) X-Ref |
Builds an XHTML opening tag with class and attributes. param: string $type The tag type ('td', 'th', 'div', etc). param: array|string $attr Additional attributes for the tag. return: string The opening tag XHTML. |
_element($label, $fieldXhtml, $validCode = null, $validMsg = null) X-Ref |
Adds an element to the table layout; auto-starts a block as needed. param: string $label The label for the element. param: string $fieldXhtml The XHTML for the element field. param: mixed $validCode A validation code. If exactly boolean param: mixed array|string $validMsg A validation message. If an return: string The element layout XHTML. |
_unquote($value) X-Ref |
Recursively removes magic quotes from values and arrays. param: mixed $value The value from which to remove magic quotes. return: mixed The un-quoted value. |
_input($type, $name, $value = null, $attr = null) X-Ref |
Builds an 'input' element. param: string $type The input type ('text', 'hidden', etc). param: string $name The element name. param: mixed $value The element value. param: array|string $attr Attributes for the element tag. return: The 'input' tag XHTML. |
_tidy($xhtml) X-Ref |
Puts in newlines and tabs to make the source code readable. param: string $xhtml The XHTML to tidy up. return: string The tidied XHTML. |
_blockStart($label = null, $type = 'col', $float = null,$clear = null) X-Ref |
Generates XHTML to start a fieldset block. param: string $label The fieldset legend. If an empty string, param: string $type The layout type to use, 'col' or 'row'. The param: string $float Whether the block should float 'left' or param: string $float Whether the block should be cleared of 'left' return: string The XHTML to start a block. |
_blockEnd() X-Ref |
Generates the XHTML to end a block. return: string The XHTML to end a block. |
_blockSplit() X-Ref |
Generates the layout to split the layout within a block. return: string The XHTML to split the layout with in a block. |
Généré le : Sun Feb 25 17:20:01 2007 | par Balluche grâce à PHPXref 0.7 |