API Documentation

ZendX/JQuery/View/Helper/JQuery/Container.php

Show: inherited
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-2010 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
ZendX_JQuery  
Subpackage
View  
Version
$Id: Container.php 24189 2011-07-05 15:08:03Z matthew $  

\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-2010 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Used_by
\ZendX_JQuery_View_Helper_UiWidgetPane  
Used_by
\ZendX_JQuery_View_Helper_JQuery_Container  
Used_by
\ZendX_JQuery_View_Helper_UiWidget  
Uses
\ZendX_JQuery_View_Helper_JQuery_Container  

Properties

PropertyprotectedBoolean  $_captureLock= 'false'

Indicates if a capture start method for javascript or onLoad has been called.

Default valuefalseDetails
Type
Boolean
PropertyprotectedBoolean  $_enabled= 'false'

Indicates wheater the jQuery View Helper is enabled.

Default valuefalseDetails
Type
Boolean
PropertyprotectedBoolean  $_isXhtml= 'false'

View is rendered in XHTML or not.

Default valuefalseDetails
Type
Boolean
PropertyprotectedArray  $_javascriptSources= 'array()'

Additional javascript files that for jQuery Helper components.

Default valuearray()Details
Type
Array
PropertyprotectedArray  $_javascriptStatements= 'array()'

Additional javascript statements that need to be executed after jQuery lib.

Default valuearray()Details
Type
Array
PropertyprotectedString  $_jqueryLibraryPath= 'null'

Path to local webserver jQuery library

Default valuenullDetails
Type
String
Propertyprotectedboolean  $_loadSslCdnPath= 'false'

Load CDN Path from SSL or Non-SSL?

Default valuefalseDetails
Type
boolean
PropertyprotectedArray  $_onLoadActions= 'array()'

jQuery onLoad statements Stack

Default valuearray()Details
Type
Array
PropertyprotectedInteger  $_renderMode= 'ZendX_JQuery::RENDER_ALL'

Default Render Mode (all parts)

Default valueZendX_JQuery::RENDER_ALLDetails
Type
Integer
PropertyprotectedArray  $_stylesheets= 'array()'

Additional stylesheet files for jQuery related components.

Default valuearray()Details
Type
Array
PropertyprotectedBoolean  $_uiEnabled= 'false'

jQuery UI Library Enabled

Default valuefalseDetails
Type
Boolean
PropertyprotectedString  $_uiPath= 'null'

Local jQuery UI Path. Use Google CDN if variable is null

Default valuenullDetails
Type
String
PropertyprotectedString  $_uiVersion= 'ZendX_JQuery::DEFAULT_UI_VERSION'

jQuery UI Google CDN Version

Default valueZendX_JQuery::DEFAULT_UI_VERSIONDetails
Type
String
PropertyprotectedString  $_version= 'ZendX_JQuery::DEFAULT_JQUERY_VERSION'

Default CDN jQuery Library version

Default valueZendX_JQuery::DEFAULT_JQUERY_VERSIONDetails
Type
String
Propertypublic\Zend_View_Interface  $view= 'null'

View Instance

Default valuenullDetails
Type
\Zend_View_Interface

Methods

methodpublic__toString( ) : string

String representation of jQuery environment

Returns
Type Description
string
methodprotected_getJQueryLibraryBaseCdnUri( ) : string

Returns
Type Description
string
methodprotected_getJQueryLibraryPath( ) : string

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

Returns
Type Description
string
methodprotected_getJQueryUiLibraryBaseCdnUri( ) : string

Returns
Type Description
string
methodprotected_getJQueryUiLibraryPath( ) : string

Returns
Type Description
string
methodprotected_renderExtras( ) : string

Renders all javascript code related stuff of the jQuery enviroment.

Returns
Type Description
string
methodprotected_renderScriptTags( ) : string

Renders all javascript file related stuff of the jQuery enviroment.

Returns
Type Description
string
methodprotected_renderStylesheets( ) : string

Render jQuery stylesheets

Returns
Type Description
string
methodpublicaddJavascript( string $js ) : \ZendX_JQuery_View_Helper_JQuery_Container

Add arbitrary javascript to execute in jQuery JS container

Parameters
Name Type Description
$js string
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddJavascriptFile(  $path ) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a Javascript File to the include stack.

Parameters
Name Type Description
$path
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddOnLoad( string $callback ) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a script to execute onLoad

Parameters
Name Type Description
$callback string

Lambda

Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicaddStylesheet( string $path ) : \ZendX_JQuery_View_Helper_JQuery_Container

Add a stylesheet

Parameters
Name Type Description
$path string
Returns
Type Description
\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.

methodpublicgetCdnSsl( ) : boolean

Get Flag of SSL on CDN

Returns
Type Description
boolean True if SSL is used on CDN
methodpublicgetCdnVersion( ) : string

Get CDN version

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

Return all registered javascript statements

Returns
Type Description
array
methodpublicgetJavascriptFiles( ) : Array

Return all currently registered Javascript files.

This does not include the jQuery library, which is handled by another retrieval strategy.

Returns
Type Description
Array
methodpublicgetLocalPath( ) : string

Get local path to jQuery

Returns
Type Description
string
methodpublicgetOnLoadActions( ) : array

Retrieve all registered onLoad actions

Returns
Type Description
array
methodpublicgetRenderMode( ) : integer

Return bitmask of the current Render Mode

Returns
Type Description
integer
methodpublicgetStylesheets( ) : array

Retrieve registered stylesheets

Returns
Type Description
array
methodpublicgetUiCdnVersion( ) : String

Return jQuery UI CDN Version

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

Proxies to getUiPath() for consistency in function naming.

Returns
Type Description
string
methodpublicgetUiPath( ) : string

Return the local jQuery UI Path if set.

Returns
Type Description
string
methodpublicgetUiVersion( ) : string

Get jQuery UI Version used.

Returns
Type Description
string
methodpublicgetVersion( ) : string

Get the version used with the jQuery library

Returns
Type Description
string
methodpublicisEnabled( ) : boolean

Is jQuery enabled?

Returns
Type Description
boolean
methodpublicjavascriptCaptureEnd( ) : boolean

Finish capturing arbitrary javascript to include in jQuery script

Returns
Type Description
boolean
methodpublicjavascriptCaptureStart( ) : boolean

Capture arbitrary javascript to include in jQuery script

Returns
Type Description
boolean
methodpubliconLoadCaptureEnd( ) : boolean

Stop capturing routines to run onLoad

Returns
Type Description
boolean
methodpubliconLoadCaptureStart( ) : boolean

Start capturing routines to run onLoad

Returns
Type Description
boolean
methodpublicsetCdnSsl(  $flag ) : \ZendX_JQuery_View_Helper_JQuery_Container

Set Use SSL on CDN Flag

Parameters
Name Type Description
$flag
Returns
Type Description
\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
Name Type Description
$version string
Returns
Type Description
\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
Name Type Description
$path string
Returns
Type Description
\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
Name Type Description
$mask integer
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
Details
See
\ZendX_JQuery::RENDER_ALL  
methodpublicsetUiCdnVersion( String $version = "1.5.2" ) : \ZendX_JQuery_View_Helper_JQuery_Container

Set jQuery UI CDN Version

Parameters
Name Type Description
$version String
Returns
Type Description
\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
Name Type Description
$path String
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetUiVersion( string $version ) : \ZendX_JQuery_View_Helper_JQuery_Container

Set jQuery UI version used.

Parameters
Name Type Description
$version string
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetVersion( string $version ) : \ZendX_JQuery_View_Helper_JQuery_Container

Set the version of the jQuery library used.

Parameters
Name Type Description
$version string
Returns
Type Description
\ZendX_JQuery_View_Helper_JQuery_Container
methodpublicsetView( \Zend_View_Interface $view ) : void

Set view object

Parameters
Name Type Description
$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
Type Description
boolean
methodpublicuseCdn( ) : boolean

Are we using the CDN?

Returns
Type Description
boolean
methodpublicuseLocalPath( ) : boolean

Are we using a local path?

Returns
Type Description
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
Type Description
boolean
Documentation was generated by DocBlox 0.15.1.