[ Index ]
 

Code source de PRADO 3.0.6

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/framework/Web/UI/WebControls/ -> TCheckBox.php (sommaire)

TCheckBox class file

Author: Qiang Xue <qiang.xue@gmail.com>
Copyright: Copyright © 2005 PradoSoft
License: http://www.pradosoft.com/license/
Version: $Id: TCheckBox.php 1397 2006-09-07 07:55:53Z wei $
Poids: 425 lignes (13 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 2 classes

TCheckBox:: (27 méthodes):
  getTagName()
  loadPostData()
  raisePostDataChangedEvent()
  onCheckedChanged()
  onPreRender()
  getValidationPropertyValue()
  getText()
  setText()
  getValue()
  setValue()
  getTextAlign()
  setTextAlign()
  getChecked()
  setChecked()
  getAutoPostBack()
  setAutoPostBack()
  getCausesValidation()
  setCausesValidation()
  getValidationGroup()
  setValidationGroup()
  render()
  getLabelAttributes()
  getInputAttributes()
  getValueAttribute()
  renderLabel()
  renderInputTag()
  getPostBackOptions()

TTextAlign:: (0 méthodes):


Classe: TCheckBox  - X-Ref

TCheckBox class

TCheckBox displays a check box on the page.
You can specify the caption to display beside the check box by setting
the {@link setText Text} property.  The caption can appear either on the right
or left of the check box, which is determined by the {@link setTextAlign TextAlign}
property.

To determine whether the TCheckBox component is checked, test the {@link getChecked Checked}
property. The {@link onCheckedChanged OnCheckedChanged} event is raised when
the {@link getChecked Checked} state of the TCheckBox component changes
between posts to the server. You can provide an event handler for
the {@link onCheckedChanged OnCheckedChanged} event to  to programmatically
control the actions performed when the state of the TCheckBox component changes
between posts to the server.

If {@link setAutoPostBack AutoPostBack} is set true, changing the check box state
will cause postback action. And if {@link setCausesValidation CausesValidation}
is true, validation will also be processed, which can be further restricted within
a {@link setValidationGroup ValidationGroup}.

Note, {@link setText Text} is rendered as is. Make sure it does not contain unwanted characters
that may bring security vulnerabilities.

getTagName()   X-Ref

return: string tag name of the button

loadPostData($key,$values)   X-Ref
Loads user input data.
This method is primarly used by framework developers.

param: string the key that can be used to retrieve data from the input data collection
param: array the input data collection
return: boolean whether the data of the control has been changed

raisePostDataChangedEvent()   X-Ref
Raises postdata changed event.
This method raises {@link onCheckedChanged OnCheckedChanged} event.
This method is primarly used by framework developers.


onCheckedChanged($param)   X-Ref
Raises <b>OnCheckedChanged</b> event when {@link getChecked Checked} changes value during postback.
If you override this method, be sure to call the parent implementation
so that the event delegates can be invoked.

param: TEventParameter event parameter to be passed to the event handlers

onPreRender($param)   X-Ref
Registers the checkbox to receive postback data during postback.
This is necessary because a checkbox if unchecked, when postback,
does not have direct mapping between post data and the checkbox name.

This method overrides the parent implementation and is invoked before render.
param: mixed event parameter

getValidationPropertyValue()   X-Ref
Returns the value of the property that needs validation.

return: mixed the property value to be validated

getText()   X-Ref

return: string the text caption of the checkbox

setText($value)   X-Ref
Sets the text caption of the checkbox.

param: string the text caption to be set

getValue()   X-Ref

return: string the value of the checkbox. Defaults to empty.

setValue($value)   X-Ref

param: string the value of the checkbox

getTextAlign()   X-Ref

return: TTextAlign the alignment (Left or Right) of the text caption, defaults to TTextAlign::Right.

setTextAlign($value)   X-Ref

param: TTextAlign the alignment of the text caption. Valid values include Left and Right.

getChecked()   X-Ref

return: boolean whether the checkbox is checked

setChecked($value)   X-Ref
Sets a value indicating whether the checkbox is to be checked or not.

param: boolean whether the checkbox is to be checked or not.

getAutoPostBack()   X-Ref

return: boolean whether clicking on the checkbox will post the page.

setAutoPostBack($value)   X-Ref
Sets a value indicating whether clicking on the checkbox will post the page.

param: boolean whether clicking on the checkbox will post the page.

getCausesValidation()   X-Ref

return: boolean whether postback event triggered by this checkbox will cause input validation, default is true.

setCausesValidation($value)   X-Ref
Sets the value indicating whether postback event trigger by this checkbox will cause input validation.

param: boolean whether postback event trigger by this checkbox will cause input validation.

getValidationGroup()   X-Ref

return: string the group of validators which the checkbox causes validation upon postback

setValidationGroup($value)   X-Ref

param: string the group of validators which the checkbox causes validation upon postback

render($writer)   X-Ref
Renders the checkbox control.
This method overrides the parent implementation by rendering a checkbox input element
and a span element if needed.

param: THtmlWriter the writer used for the rendering purpose

getLabelAttributes()   X-Ref

return: TMap list of attributes to be rendered for label beside the checkbox

getInputAttributes()   X-Ref

return: TMap list of attributes to be rendered for the checkbox

getValueAttribute()   X-Ref

return: string the value attribute to be rendered

renderLabel($writer,$clientID,$text)   X-Ref
Renders a label beside the checkbox.

param: THtmlWriter the writer for the rendering purpose
param: string checkbox id
param: string label text

renderInputTag($writer,$clientID,$onclick)   X-Ref
Renders a checkbox input element.

param: THtmlWriter the writer for the rendering purpose
param: string checkbox id
param: string onclick js

getPostBackOptions()   X-Ref
Gets the post back options for this checkbox.

return: array

Classe: TTextAlign  - X-Ref

TTextAlign class.
TTextAlign defines the enumerable type for the possible text alignments

The following enumerable values are defined:
- Left: left aligned
- Right: right aligned



Généré le : Sun Feb 25 21:07:04 2007 par Balluche grâce à PHPXref 0.7