Constructor.
TClientScriptManager
__construct
(TPage $owner)
-
TPage
$owner: page that owns this client script manager
Returns javascript statement that create a new callback request object.
string
getCallbackReference
(ICallbackEventHandler $callbackHandler, [array $options = null])
-
ICallbackEventHandler
$callbackHandler: callback response handler
-
array
$options: additional callback options
string
getPradoScriptBasePath
()
boolean
hasBeginScripts
()
boolean
isBeginScriptRegistered
(string $key)
-
string
$key: a unique key
boolean
isEndScriptRegistered
(string $key)
-
string
$key: a unique key
boolean
isHeadScriptFileRegistered
(string $key)
-
string
$key: a unique key
boolean
isHeadScriptRegistered
(string $key)
-
string
$key: a unique key
boolean
isHiddenFieldRegistered
(string $key)
-
string
$key: a unique key
boolean
isScriptFileRegistered
(string $key)
-
string
$key: a unique key
boolean
isStyleSheetFileRegistered
(string $key)
-
string
$key: a unique key
boolean
isStyleSheetRegistered
(string $key)
-
string
$key: a unique key
Registers a javascript script block at the beginning of the form
void
registerBeginScript
(string $key, string $script)
-
string
$key: a unique key identifying the script block
-
string
$script: javascript block
Registers callback javascript for a control.
void
registerCallbackControl
(string $class, array $options)
-
string
$class: javascript class responsible for the control being registered for callback
-
array
$options: callback options
Register a default button to panel. When the $panel is in focus and the 'enter' key is pressed, the $button will be clicked.
-
TControl
$panel: panel to register the default button action
-
TControl
$button: button to trigger a postback
Registers a javascript script block at the end of the form
void
registerEndScript
(string $key, string $script)
-
string
$key: a unique key identifying the script block
-
string
$script: javascript block
Registers the control to receive default focus.
void
registerFocusControl
(string $target)
-
string
$target: the client ID of the control to receive default focus
Registers a javascript block in the page head.
void
registerHeadScript
(string $key, string $script)
-
string
$key: a unique key identifying the script block
-
string
$script: javascript block
Registers a javascript file in the page head
void
registerHeadScriptFile
(string $key, string $url)
-
string
$key: a unique key identifying the file
-
string
$url: URL to the javascript file
Registers a hidden field to be rendered in the form.
void
registerHiddenField
(string $name, string|array $value)
-
string
$name: a unique key identifying the hidden field
-
string|array
$value: hidden field value, if the value is an array, every element in the array will be rendered as a hidden field value.
Registers postback javascript for a control. A null class parameter will prevent the javascript code registration.
void
registerPostBackControl
(string $class, array $options)
-
string
$class: javascript class responsible for the control being registered for postback
-
array
$options: postback options
Registers Prado scripts by library name.
Each library may include one or several script files. Currently, the following libraries are available:
- prado : basic prado js framework
- effects :
- ajax : ajax related js
- validator : validator js
- logger : js logger
- datepicker : datepicker js
- rico :
- colorpicker : colorpicker js
The script files registered will be published.
void
registerPradoScript
(string $name)
-
string
$name: script library name.
Registers a javascript file to be rendered within the form
void
registerScriptFile
(string $key, string $url)
-
string
$key: a unique key identifying the file
-
string
$url: URL to the javascript file to be rendered
Registers a CSS block to be rendered in the page head
void
registerStyleSheet
(string $key, string $css, [mixed $media = ''])
-
string
$key: a unique key identifying the CSS block
-
string
$css: CSS block
Registers a CSS file to be rendered in the page head
void
registerStyleSheetFile
(string $key, string $url, [string $media = ''])
-
string
$key: a unique key identifying the file
-
string
$url: URL to the CSS file
-
string
$media: media type of the CSS (such as 'print', 'screen', etc.). Defaults to empty, meaning the CSS applies to all media types.
Renders the HTML tags for PRADO js files
Inherited Methods
Inherited From TApplicationComponent
TApplicationComponent::getApplication()
TApplicationComponent::getRequest()
TApplicationComponent::getResponse()
TApplicationComponent::getService()
TApplicationComponent::getSession()
TApplicationComponent::getUser()
TApplicationComponent::publishAsset()
TApplicationComponent::publishFilePath()
Inherited From TComponent
TComponent::addParsedObject()
TComponent::attachEventHandler()
TComponent::canGetProperty()
TComponent::canSetProperty()
TComponent::createdOnTemplate()
TComponent::detachEventHandler()
TComponent::evaluateExpression()
TComponent::evaluateStatements()
TComponent::getEventHandlers()
TComponent::getSubProperty()
TComponent::hasEvent()
TComponent::hasEventHandler()
TComponent::hasProperty()
TComponent::raiseEvent()
TComponent::setSubProperty()
TComponent::__get()
TComponent::__set()