JQuery/View/Helper/JQuery/Container.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework
LICENSE This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
Category
ZendX  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
ZendX_JQuery  
Subpackage
View  
Version
$Id$  

\ZendX_JQuery_View_Helper_JQuery_Container

Package: ZendX_JQuery\View
jQuery View Helper. Transports all jQuery stack and render information across all views.
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Uses
 

Properties

>VPropertyprotectedBoolean $_captureLock = false
Indicates if a capture start method for javascript or onLoad has been called.
Default valuefalseDetails
Type
Boolean
>VPropertyprotectedBoolean $_enabled = false
Indicates wheater the jQuery View Helper is enabled.
Default valuefalseDetails
Type
Boolean
>VPropertyprotectedBoolean $_isXhtml = false
View is rendered in XHTML or not.
Default valuefalseDetails
Type
Boolean
>VPropertyprotectedArray $_javascriptSources = array()
Additional javascript files that for jQuery Helper components.
Default valuearray()Details
Type
Array
>VPropertyprotectedArray $_javascriptStatements = array()
Additional javascript statements that need to be executed after jQuery lib.
Default valuearray()Details
Type
Array
>VPropertyprotectedString $_jqueryLibraryPath = null
Path to local webserver jQuery library
Default valuenullDetails
Type
String
>VPropertyprotectedboolean $_loadSslCdnPath = false
Load CDN Path from SSL or Non-SSL?
Default valuefalseDetails
Type
boolean
>VPropertyprotectedArray $_onLoadActions = array()
jQuery onLoad statements Stack
Default valuearray()Details
Type
Array
>VPropertyprotectedInteger $_renderMode = \ZendX_JQuery::RENDER_ALL
Default Render Mode (all parts)
Default value\ZendX_JQuery::RENDER_ALLDetails
Type
Integer
>VPropertyprotectedArray $_stylesheets = array()
Additional stylesheet files for jQuery related components.
Default valuearray()Details
Type
Array
>VPropertyprotectedBoolean $_uiEnabled = false
jQuery UI Library Enabled
Default valuefalseDetails
Type
Boolean
>VPropertyprotectedString $_uiPath = null
Local jQuery UI Path. Use Google CDN if variable is null
Default valuenullDetails
Type
String
>VPropertyprotectedString $_uiVersion = \ZendX_JQuery::DEFAULT_UI_VERSION
jQuery UI Google CDN Version
Default value\ZendX_JQuery::DEFAULT_UI_VERSIONDetails
Type
String
>VPropertyprotectedString $_version = \ZendX_JQuery::DEFAULT_JQUERY_VERSION
Default CDN jQuery Library version
Default value\ZendX_JQuery::DEFAULT_JQUERY_VERSIONDetails
Type
String
>VPropertypublic\Zend_View_Interface $view = null
View Instance
Default valuenullDetails
Type
\Zend_View_Interface

Methods

methodpublic__toString() : string

String representation of jQuery environment

Returns
TypeDescription
string
methodprotected_getJQueryLibraryBaseCdnUri() : string

Returns
TypeDescription
string
methodprotected_getJQueryLibraryPath() : string

Internal function that constructs the include path of the jQuery library.

Returns
TypeDescription
string
methodprotected_getJQueryUiLibraryBaseCdnUri() : string

Returns
TypeDescription
string
methodprotected_getJQueryUiLibraryPath() : string

Internal function that constructs the include path of the jQueryUI library.

Returns
TypeDescription
string
methodprotected_renderExtras() : string

Renders all javascript code related stuff of the jQuery enviroment.

Returns
TypeDescription
string
methodprotected_renderScriptTags() : string

Renders all javascript file related stuff of the jQuery enviroment.

Returns
TypeDescription
string
methodprotected_renderStylesheets() : string

Render jQuery stylesheets

Returns
TypeDescription
string
methodpublicaddJavascript(string $js) : \ZendX_JQuery_View_Helper_JQuery_Container

Add arbitrary javascript to execute in jQuery JS container

Parameters
NameTypeDescription
$jsstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddJavascriptFile(string $path) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a Javascript File to the include stack.

Parameters
NameTypeDescription
$pathstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddOnLoad(string $callback) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a script to execute onLoad

Parameters
NameTypeDescription
$callbackstring

Lambda

Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddStylesheet(string $path) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a stylesheet

Parameters
NameTypeDescription
$pathstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicclearJavascript() : \ZendX_JQuery_View_Helper_JQuery_Container

Clear arbitrary javascript stack

methodpublicclearJavascriptFiles() : \ZendX_JQuery_View_Helper_JQuery_Container

Clear all currently registered Javascript files.

methodpublicclearOnLoadActions() : \ZendX_JQuery_View_Helper_JQuery_Container

Clear the onLoadActions stack.

methodpublicclearStylesheets() : \ZendX_JQuery_View_Helper_JQuery_Container

Clear all currently registered stylesheets files

methodpublicgetCdnSsl() : boolean

Get Flag of SSL on CDN

Returns
TypeDescription
booleanTrue if SSL is used on CDN
methodpublicgetCdnVersion() : string

Get CDN version

Returns
TypeDescription
string
Details
Deprecated
As of version 1.8, use {@link getVersion()} instead.  
methodpublicgetJavascript() : array

Return all registered javascript statements

Returns
TypeDescription
array
methodpublicgetJavascriptFiles() : array

Return all currently registered Javascript files.

This does not include the jQuery library, which is handled by another retrieval strategy.
Returns
TypeDescription
array
methodpublicgetLocalPath() : string

Get local path to jQuery

Returns
TypeDescription
string
methodpublicgetOnLoadActions() : array

Retrieve all registered onLoad actions

Returns
TypeDescription
array
methodpublicgetRenderMode() : integer

Return bitmask of the current Render Mode

Returns
TypeDescription
integer
methodpublicgetStylesheets() : array

Retrieve registered stylesheets

Returns
TypeDescription
array
methodpublicgetUiCdnVersion() : String

Return jQuery UI CDN Version

Returns
TypeDescription
String
Details
Deprecated
As of 1.8 use {@link getUiVersion()}  
methodpublicgetUiLocalPath() : string

Proxies to getUiPath() for consistency in function naming.

Returns
TypeDescription
string
methodpublicgetUiPath() : string

Return the local jQuery UI Path if set.

Returns
TypeDescription
string
methodpublicgetUiVersion() : string

Get jQuery UI Version used.

Returns
TypeDescription
string
methodpublicgetVersion() : string

Get the version used with the jQuery library

Returns
TypeDescription
string
methodpublicisEnabled() : boolean

Is jQuery enabled?

Returns
TypeDescription
boolean
methodpublicjavascriptCaptureEnd() : boolean

Finish capturing arbitrary javascript to include in jQuery script

Returns
TypeDescription
boolean
methodpublicjavascriptCaptureStart() : boolean

Capture arbitrary javascript to include in jQuery script

Returns
TypeDescription
boolean
Throws
ExceptionDescription
\Zend_Exception
methodpubliconLoadCaptureEnd() : boolean

Stop capturing routines to run onLoad

Returns
TypeDescription
boolean
methodpubliconLoadCaptureStart() : boolean

Start capturing routines to run onLoad

Returns
TypeDescription
boolean
Throws
ExceptionDescription
\Zend_Exception
methodpublicsetCdnSsl(bool $flag) : \ZendX_JQuery_View_Helper_JQuery_Container

Set Use SSL on CDN Flag

Parameters
NameTypeDescription
$flagbool
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetCdnVersion(string $version = null) : \ZendX_JQuery_View_Helper_JQuery_Container

Use CDN, using version specified. Currently supported by Googles Ajax Library API are: 1.2.3, 1.2.6

Parameters
NameTypeDescription
$versionstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
Details
Deprecated
As of version 1.8, use {@link setVersion()} instead.  
methodpublicsetLocalPath(string $path) : \ZendX_JQuery_View_Helper_JQuery_Container

Set path to local jQuery library

Parameters
NameTypeDescription
$pathstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetRenderMode(integer $mask) : \ZendX_JQuery_View_Helper_JQuery_Container

Set which parts of the jQuery enviroment should be rendered.

This function allows for a gradual refactoring of the jQuery code rendered by calling __toString(). Use ZendX_JQuery::RENDER_* constants. By default all parts of the enviroment are rendered.
Parameters
NameTypeDescription
$maskinteger
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
Details
See
 
methodpublicsetUiCdnVersion(string $version = '1.5.2') : \ZendX_JQuery_View_Helper_JQuery_Container

Set jQuery UI CDN Version

Parameters
NameTypeDescription
$versionstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
Details
Deprecated
As of 1.8 use {@link setUiVersion()}  
methodpublicsetUiLocalPath(String $path) : \ZendX_JQuery_View_Helper_JQuery_Container

Set local path to jQuery UI library

Parameters
NameTypeDescription
$pathString
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetUiVersion(string $version) : \ZendX_JQuery_View_Helper_JQuery_Container

Set jQuery UI version used.

Parameters
NameTypeDescription
$versionstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetVersion(string $version) : \ZendX_JQuery_View_Helper_JQuery_Container

Set the version of the jQuery library used.

Parameters
NameTypeDescription
$versionstring
Returns
TypeDescription
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetView(\Zend_View_Interface $view) : void

Set view object

Parameters
NameTypeDescription
$view\Zend_View_Interface
methodpublicuiDisable() : \ZendX_JQuery_View_Helper_JQuery_Container

Disable jQuery UI Library Rendering

methodpublicuiEnable() : \ZendX_JQuery_View_Helper_JQuery_Container

Enable jQuery UI Library Rendering

methodpublicuiIsEnabled() : boolean

Check wheater currently the jQuery UI library is enabled.

Returns
TypeDescription
boolean
methodpublicuseCdn() : boolean

Are we using the CDN?

Returns
TypeDescription
boolean
methodpublicuseLocalPath() : boolean

Are we using a local path?

Returns
TypeDescription
boolean
methodpublicuseUiCdn() : \ZendX_JQuery_View_Helper_JQuery_Container

Is the jQuery Ui enabled and loaded from CDN?

methodpublicuseUiLocal() : boolean

Is the jQuery Ui loaded from local scope?

Returns
TypeDescription
boolean
Documentation was generated by phpDocumentor 2.2.0 .