PHP Class Prado\Web\UI\ActiveControls\TActiveImageButton

TActiveImageButton is the active control counter part to TImageButton. When a TActiveImageButton is clicked, rather than a normal post back request a callback request is initiated. The {@link onCallback OnCallback} event is raised during a callback request and it is raise after the {@link onClick OnClick} event.
Since: 3.1
Inheritance: extends Prado\Web\UI\WebControls\TImageButton, implements Prado\Web\UI\ActiveControls\IActiveControl, implements Prado\Web\UI\ActiveControls\ICallbackEventHandler
Afficher le fichier Open project: pradosoft/prado Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( ) Creates a new callback control, sets the adapter to TActiveControlAdapter. If you override this class, be sure to set the adapter appropriately by, for example, by calling this constructor.
getActiveControl ( ) : TBaseActiveControl
getClientSide ( ) : TCallbackClientSide
onCallback ( $param ) This method is invoked when a callback is requested. The method raises 'OnCallback' event to fire up the event handlers. If you override this method, be sure to call the parent implementation so that the event handler can be invoked.
raiseCallbackEvent ( $param ) Raises the callback event. This method is required by {@link ICallbackEventHandler ICallbackEventHandler} interface. If {@link getCausesValidation CausesValidation} is true, it will invoke the page's {@link TPage::validate} method first. It will raise {@link onClick OnClick} event first and then the {@link onCallback OnCallback} event.
setAlternateText ( $value ) Sets the alternative text to be displayed in the TImage when the image is unavailable.
setDescriptionUrl ( $value )
setImageAlign ( $value ) Sets the alignment of the image with respective to other elements on the page.
setImageUrl ( $value )

Méthodes protégées

Méthode Description
addAttributesToRender ( $writer ) Ensure that the ID attribute is rendered and registers the javascript code for initializing the active control.
getClientClassName ( ) : string
renderClientControlScript ( $writer ) Override parent implementation, no javascript is rendered here instead the javascript required for active control is registered in {@link addAttributesToRender}.

Method Details

__construct() public méthode

Creates a new callback control, sets the adapter to TActiveControlAdapter. If you override this class, be sure to set the adapter appropriately by, for example, by calling this constructor.
public __construct ( )

addAttributesToRender() protected méthode

Ensure that the ID attribute is rendered and registers the javascript code for initializing the active control.
protected addAttributesToRender ( $writer )

getActiveControl() public méthode

public getActiveControl ( ) : TBaseActiveControl
Résultat TBaseActiveControl basic active control options.

getClientClassName() protected méthode

protected getClientClassName ( ) : string
Résultat string corresponding javascript class name for this TActiveLinkButton.

getClientSide() public méthode

public getClientSide ( ) : TCallbackClientSide
Résultat TCallbackClientSide client side request options.

onCallback() public méthode

This method is invoked when a callback is requested. The method raises 'OnCallback' event to fire up the event handlers. If you override this method, be sure to call the parent implementation so that the event handler can be invoked.
public onCallback ( $param )

raiseCallbackEvent() public méthode

This method is mainly used by framework and control developers.
public raiseCallbackEvent ( $param )

renderClientControlScript() protected méthode

Override parent implementation, no javascript is rendered here instead the javascript required for active control is registered in {@link addAttributesToRender}.
protected renderClientControlScript ( $writer )

setAlternateText() public méthode

Sets the alternative text to be displayed in the TImage when the image is unavailable.
public setAlternateText ( $value )

setDescriptionUrl() public méthode

public setDescriptionUrl ( $value )

setImageAlign() public méthode

Possible values include: absbottom, absmiddle, baseline, bottom, left, middle, right, texttop, and top. If an empty string is passed in, imagealign attribute will not be rendered.
public setImageAlign ( $value )

setImageUrl() public méthode

public setImageUrl ( $value )