Méthode | Description | |
---|---|---|
__construct ( SimpleTag $tag, SimplePage $page ) | Starts with no held controls/widgets. | |
addWidget ( SimpleWidget $tag ) | Adds a tag contents to the form. | |
attachLabelBySelector ( SelectorInterface $selector, $label ) | Used by the page object to set widgets labels to external label tags. | |
getAction ( ) : SimpleUrl | Absolute URL of the target. | |
getId ( ) : string | ID field of form for unique identification. | |
getMethod ( ) : string | Accessor for method of form submission. | |
getValue ( SelectorInterface $selector ) : string/array | Extracts current value from form. | |
hasImage ( SelectorInterface $selector ) : boolean | Test to see if a form has an image control. | |
hasSubmit ( SelectorInterface $selector ) : boolean | Test to see if a form has a submit button. | |
setDefaultTarget ( string $frame ) | Sets the frame target within a frameset. | |
setField ( SelectorInterface $selector, string $value, $position = false ) : boolean | Sets a widget value within the form. | |
submit ( $additional = false ) : hash | Simply submits the form without the submit button value. | |
submitButton ( SelectorInterface $selector, hash $additional = false ) : SimpleEncoding | Gets the submit values for a selected button. | |
submitImage ( SelectorInterface $selector, integer $x, integer $y, hash $additional = false ) : SimpleEncoding | Gets the submit values for an image. |
Méthode | Description | |
---|---|---|
addCheckbox ( SimpleCheckboxTag $tag ) | Adds a checkbox, making it a group on a repeated name. | |
addRadioButton ( SimpleRadioButtonTag $tag ) | Adds a radio button, building a group if necessary. | |
createAction ( string $action, $page ) : SimpleUrl | Combined action attribute with current location to get an absolute form target. | |
encode ( ) : SimpleFormEncoding | Creates the encoding for the current values in the form. | |
setEncodingClass ( SimpleTag $tag ) : string | Creates the request packet to be sent by the form. | |
setWidget ( SimpleWidget $tag ) | Sets the widget into the form, grouping radio buttons if any. |
public __construct ( SimpleTag $tag, SimplePage $page ) | ||
$tag | SimpleTag | Form tag to read. |
$page | SimplePage | Holding page. |
protected addCheckbox ( SimpleCheckboxTag $tag ) | ||
$tag | SimpleCheckboxTag | Incoming form control. |
protected addRadioButton ( SimpleRadioButtonTag $tag ) | ||
$tag | SimpleRadioButtonTag | Incoming form control. |
public addWidget ( SimpleWidget $tag ) | ||
$tag | SimpleWidget | Input tag to add. |
public attachLabelBySelector ( SelectorInterface $selector, $label ) | ||
$selector | SelectorInterface | Criteria to apply. |
protected createAction ( string $action, $page ) : SimpleUrl | ||
$action | string | Action attribute from form tag. |
$page | Page location. | |
Résultat | SimpleUrl | Absolute form target. |
protected encode ( ) : SimpleFormEncoding | ||
Résultat | SimpleFormEncoding | Request to submit. |
public getAction ( ) : SimpleUrl | ||
Résultat | SimpleUrl | URL target. |
public getValue ( SelectorInterface $selector ) : string/array | ||
$selector | SelectorInterface | Criteria to apply. |
Résultat | string/array |
public setDefaultTarget ( string $frame ) | ||
$frame | string | Name of frame. |
protected setEncodingClass ( SimpleTag $tag ) : string | ||
$tag | SimpleTag | Form tag to read. |
Résultat | string | Packet class. |
protected setWidget ( SimpleWidget $tag ) | ||
$tag | SimpleWidget | Incoming form control. |
public submit ( $additional = false ) : hash | ||
Résultat | hash | Submitted values. |
public submitButton ( SelectorInterface $selector, hash $additional = false ) : SimpleEncoding | ||
$selector | SelectorInterface | Criteria to apply. |
$additional | hash | Additional data for the form. |
Résultat | SimpleEncoding | Submitted values or false if there is no such button in the form. |
public submitImage ( SelectorInterface $selector, integer $x, integer $y, hash $additional = false ) : SimpleEncoding | ||
$selector | SelectorInterface | Criteria to apply. |
$x | integer | X-coordinate of click. |
$y | integer | Y-coordinate of click. |
$additional | hash | Additional data for the form. |
Résultat | SimpleEncoding | Submitted values or false if there is no such button in the form. |