PHP 클래스 Prado\Web\UI\WebControls\TClientScript

Allows importing of Prado Client Scripts from template via the {@link setPradoScripts PradoScripts} property. Multiple Prado client-scripts can be specified using comma delimited string of the javascript library to include on the page. For example, Custom javascript files can be register using the {@link setScriptUrl ScriptUrl} property. /> Contents within TClientScript will be treated as javascript code and will be rendered in place. Since Prado 3.2 the property {@link setFlushScriptFiles FlushScriptFiles} controls whether Prado will flush the script files defined in the page before rendering the TClientScript contents. If you're not using any external functions in your TClientScript block, you should set the {@link setFlushScriptFiles FlushScriptFiles} property to false, so Prado can postpone the loading of all the referenced script files further down the page generation cycle.
부터: 3.0
상속: extends Prado\Web\UI\TControl
파일 보기 프로젝트 열기: pradosoft/prado

공개 메소드들

메소드 설명
getFlushScriptFiles ( ) : boolean
getPradoScripts ( ) : string
getScriptUrl ( ) : string
onPreRender ( $param ) Calls the client script manager to add each of the requested client script libraries.
render ( $writer ) Renders the body content as javascript block.
setFlushScriptFiles ( $value )
setPradoScripts ( $value ) Include javascript library to the current page. The current supported libraries are: "prado", "effects", "ajax", "validator", "logger", "datepicker", "colorpicker". Library dependencies are automatically resolved.
setScriptUrl ( $value )

보호된 메소드들

메소드 설명
renderCustomScript ( $writer ) Registers the body content as javascript.
renderCustomScriptFile ( $writer ) Renders the custom script file.

메소드 상세

getFlushScriptFiles() 공개 메소드

public getFlushScriptFiles ( ) : boolean
리턴 boolean whether to flush script files using TClientScriptManager::flushScriptFiles() before rendering the script block

getPradoScripts() 공개 메소드

public getPradoScripts ( ) : string
리턴 string comma delimited list of javascript libraries to included on the page.

getScriptUrl() 공개 메소드

public getScriptUrl ( ) : string
리턴 string custom javascript file url.

onPreRender() 공개 메소드

Calls the client script manager to add each of the requested client script libraries.
public onPreRender ( $param )

render() 공개 메소드

Overrides parent implementation, parent renderChildren method is called during {@link registerCustomScript}.
public render ( $writer )

renderCustomScript() 보호된 메소드

Registers the body content as javascript.
protected renderCustomScript ( $writer )

renderCustomScriptFile() 보호된 메소드

Renders the custom script file.
protected renderCustomScriptFile ( $writer )

setFlushScriptFiles() 공개 메소드

public setFlushScriptFiles ( $value )

setPradoScripts() 공개 메소드

Include javascript library to the current page. The current supported libraries are: "prado", "effects", "ajax", "validator", "logger", "datepicker", "colorpicker". Library dependencies are automatically resolved.
public setPradoScripts ( $value )

setScriptUrl() 공개 메소드

public setScriptUrl ( $value )