Class \Prado\Web\UI\ActiveControls\TActiveLinkButton
TActiveLinkButton is the active control counter part to TLinkButton.
When a TActiveLinkButton is clicked, rather than a normal post back request a callback request is initiated.
The \Prado\Web\UI\ActiveControls\onCallback event is raised during a callback request and it is raise after the \Prado\Web\UI\ActiveControls\onClick event.
When the \Prado\Web\UI\ActiveControls\TBaseActiveCallbackControl::setEnableUpdate property is true, changing the \Prado\Web\UI\ActiveControls\setText property during callback request will update the link text upon callback response completion.
Class hierarchy
- \Prado\Web\UI\ActiveControls\TActiveLinkButton implements IActiveControl, ICallbackEventHandler
- \Prado\Web\UI\WebControls\TLinkButton implements IPostBackEventHandler, IButtonControl, IDataRenderer
- \Prado\Web\UI\WebControls\TWebControl implements IStyleable
- \Prado\Web\UI\TControl implements IRenderable, IBindable
- \Prado\TApplicationComponent
- \Prado\TComponent
Since: 3.1
public
|
__construct() : mixed
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
|
|
public
|
|
public
|
onCallback(TCallbackEventParameter $param) : mixed
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
|
raiseCallbackEvent(TCallbackEventParameter $param) : mixed
Raises the callback event. This method is required by
{@see ICallbackEventHandlerICallbackEventHandler} interface. If
{@see getCausesValidation CausesValidation} is true, it will
invoke the page's {@see \Prado\Web\UI\TPage::validate validate} method first. It will raise
{@see onClick OnClick} event first and then the {@see onCallback OnCallback}
event.
This method is mainly used by framework and control developers. |
public
|
setEnabled(bool $value) : mixed
Ensures that the anchor is rendered correctly when its Enabled property
changes in a callback
|
public
|
setText(string $value) : mixed
Updates the link text on the client-side if the
{@see setEnableUpdate EnableUpdate} property is set to true.
|
protected
|
addAttributesToRender(mixed $writer) : mixed
Ensure that the ID attribute is rendered and registers the javascript code
for initializing the active control.
|
protected
|
getClientClassName() : string
Gets the name of the javascript class responsible for performing postback for this control.
|
protected
|
renderClientControlScript(mixed $writer) : mixed
Override parent implementation, no javascript is rendered here instead
the javascript required for active control is registered in {@see addAttributesToRender}.
|