You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
65 lines
1.2 KiB
65 lines
1.2 KiB
|
9 years ago
|
<?php
|
||
|
|
/* For licensing terms, see /license.txt */
|
||
|
9 years ago
|
|
||
|
9 years ago
|
/**
|
||
|
|
* The google maps class allows to use
|
||
|
|
* @author José Loguercio Silva <jose.loguercio@beeznest.com>
|
||
|
|
* @package chamilo.plugin.google_maps
|
||
|
|
*/
|
||
|
9 years ago
|
class GoogleMapsPlugin extends Plugin
|
||
|
9 years ago
|
{
|
||
|
|
/**
|
||
|
|
* Class constructor
|
||
|
|
*/
|
||
|
|
protected function __construct()
|
||
|
|
{
|
||
|
|
$parameters = array(
|
||
|
9 years ago
|
'enable_api' => 'boolean',
|
||
|
9 years ago
|
'api_key' => 'text',
|
||
|
|
'extra_field_name' => 'text'
|
||
|
9 years ago
|
);
|
||
|
|
|
||
|
|
parent::__construct('1.0', 'José Loguercio Silva', $parameters);
|
||
|
|
}
|
||
|
|
|
||
|
9 years ago
|
/**
|
||
|
|
* Get the plugin Name
|
||
|
|
*
|
||
|
|
* @return string
|
||
|
|
*/
|
||
|
|
public function get_name()
|
||
|
|
{
|
||
|
|
return "google_maps";
|
||
|
|
}
|
||
|
|
|
||
|
9 years ago
|
/**
|
||
|
|
* Instance the plugin
|
||
|
|
* @staticvar null $result
|
||
|
9 years ago
|
* @return GoogleMapsPlugin
|
||
|
9 years ago
|
*/
|
||
|
|
static function create()
|
||
|
|
{
|
||
|
|
static $result = null;
|
||
|
|
|
||
|
|
return $result ? $result : $result = new self();
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* Install the plugin
|
||
|
|
* @return void
|
||
|
|
*/
|
||
|
|
public function install()
|
||
|
|
{
|
||
|
9 years ago
|
return true;
|
||
|
9 years ago
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* Uninstall the plugin
|
||
|
|
* @return void
|
||
|
|
*/
|
||
|
|
public function uninstall()
|
||
|
|
{
|
||
|
9 years ago
|
return true;
|
||
|
9 years ago
|
}
|
||
|
|
}
|