Overview

Packages

  • application
    • commands
    • components
      • actions
      • filters
      • leftWidget
      • permissions
      • sortableWidget
      • util
      • webupdater
      • x2flow
        • actions
        • triggers
      • X2GridView
      • X2Settings
    • controllers
    • models
      • embedded
    • modules
      • accounts
        • controllers
        • models
      • actions
        • controllers
        • models
      • calendar
        • controllers
        • models
      • charts
        • models
      • contacts
        • controllers
        • models
      • docs
        • components
        • controllers
        • models
      • groups
        • controllers
        • models
      • marketing
        • components
        • controllers
        • models
      • media
        • controllers
        • models
      • mobile
        • components
      • opportunities
        • controllers
        • models
      • products
        • controllers
        • models
      • quotes
        • controllers
        • models
      • services
        • controllers
        • models
      • template
        • models
      • users
        • controllers
        • models
      • workflow
        • controllers
        • models
      • x2Leads
        • controllers
        • models
  • Net
  • None
  • PHP
  • system
    • base
    • caching
      • dependencies
    • collections
    • console
    • db
      • ar
      • schema
        • cubrid
        • mssql
        • mysql
        • oci
        • pgsql
        • sqlite
    • i18n
      • gettext
    • logging
    • test
    • utils
    • validators
    • web
      • actions
      • auth
      • filters
      • form
      • helpers
      • renderers
      • services
      • widgets
        • captcha
        • pagers
  • Text
    • Highlighter
  • zii
    • behaviors
    • widgets
      • grid
      • jui

Classes

  • CGoogleApi
  • CHtml
  • CJavaScript
  • CJavaScriptExpression
  • CJSON
  • X2Html
  • Overview
  • Package
  • Class
  • Tree

Class CGoogleApi

CGoogleApi provides helper methods to easily access the Google API loader.

Package: system\web\helpers
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Located at x2engine/framework/web/helpers/CGoogleApi.php
Methods summary
public static string
# init( string $apiKey = null )

Renders the jsapi script file.

Renders the jsapi script file.

Parameters

$apiKey
string
$apiKey the API key. Null if you do not have a key.

Returns

string
the script tag that loads Google jsapi.
public static string
# load( string $name, string $version = '1', array $options = array() )

Loads the specified API module. Note that you should call CGoogleApi::init() first.

Loads the specified API module. Note that you should call CGoogleApi::init() first.

Parameters

$name
string
$name the module name
$version
string
$version the module version
$options
array
$options additional js options that are to be passed to the load() function.

Returns

string
the js code for loading the module. You can use CHtml::script() to enclose it in a script tag.
public static
# register( string $name, string $version = '1', array $options = array(), string $apiKey = null )

Registers the specified API module. This is similar to CGoogleApi::load() except that it registers the loading code with CClientScript instead of returning it. This method also registers the jsapi script needed by the loading call.

Registers the specified API module. This is similar to CGoogleApi::load() except that it registers the loading code with CClientScript instead of returning it. This method also registers the jsapi script needed by the loading call.

Parameters

$name
string
$name the module name
$version
string
$version the module version
$options
array
$options additional js options that are to be passed to the load() function.
$apiKey
string
$apiKey the API key. Null if you do not have a key.
Properties summary
public static string $bootstrapUrl '//www.google.com/jsapi'
#

Protocol relative url to the Google API loader which allows easy access to most of the Google AJAX APIs

Protocol relative url to the Google API loader which allows easy access to most of the Google AJAX APIs

API documentation generated by ApiGen 2.8.0