PHP Class Habari\FormControlFacet

Inheritance: extends FormControl
Datei anzeigen Open project: habari/system

Public Properties

Property Type Description
$outpre

Public Methods

Method Description
_extend ( ) Called upon construct. Sets control properties
get ( Theme $theme )
get_visualizer ( ) Provide the HTML id of the visualizer element, which is different from the input element that provides a value
parse ( ) : array Parse the values of this field and return an array of key/value components.
pre_out ( ) : string Return the HTML/script required for this control. Do it only once.
set_ajax ( string $url, boolean $ishtml = false ) : FormControlAutocomplete Set the URL to use for ajax callbacks.

Method Details

_extend() public method

Called upon construct. Sets control properties
public _extend ( )

get() public method

public get ( Theme $theme )
$theme Theme

get_visualizer() public method

Provide the HTML id of the visualizer element, which is different from the input element that provides a value
public get_visualizer ( )

parse() public method

Example: $f->value = 'tag: "llamas" tag: feline alpaca'; var_dump($f->parsed()); // ['tag' => ['llamas', 'feline'], 'text' => ['alpaca']];
public parse ( ) : array
return array The array of parsed values

pre_out() public method

Return the HTML/script required for this control. Do it only once.
public pre_out ( ) : string
return string The HTML/javascript required for this control.

set_ajax() public method

The callback needs to accept at least the search term as the POSTed parameter "q"
public set_ajax ( string $url, boolean $ishtml = false ) : FormControlAutocomplete
$url string The URL to submit the AJAX request to
$ishtml boolean If true, the display response returned via AJAX is to be rendered as HTML (unescaped)
return FormControlAutocomplete $this

Property Details

$outpre static_oe public_oe property

static public $outpre