aboutsummaryrefslogtreecommitdiff
path: root/gmap_arcgis.module
diff options
context:
space:
mode:
Diffstat (limited to 'gmap_arcgis.module')
-rw-r--r--gmap_arcgis.module8
1 files changed, 5 insertions, 3 deletions
diff --git a/gmap_arcgis.module b/gmap_arcgis.module
index 684029d..f69b0e2 100644
--- a/gmap_arcgis.module
+++ b/gmap_arcgis.module
@@ -26,6 +26,8 @@ function gmap_arcgis_gmap($op, &$map) {
* a given map instance.
*/
if (isset($map['arcgis'])) {
+ global $base_url;
+
/**
* Make sure that shapes js code are loaded.
*
@@ -43,12 +45,12 @@ function gmap_arcgis_gmap($op, &$map) {
* The order to load the following js code is important.
*/
// Add Google js API
- $key = variable_get('googlemap_api_key', '');
+ $key = variable_get('gmap_api_key', '');
$script = '<script type="text/javascript" ';
- drupal_set_html_head($script . 'src="http://www.google.com/jsapi?key=' . $key . '"></script>');
+ drupal_set_html_head($script . 'src="http://www.google.com/jsapi?key=' . $key . '&sensor=true&language=pt-BR"></script>');
// Add ArcGIS js API
- drupal_set_html_head($script . 'src="http://serverapi.arcgisonline.com/jsapi/gmaps/?v=1.6"></script>');
+ drupal_set_html_head($script . 'src="'. $base_url .'/sites/all/libraries/google-maps-utility-library-v3/arcgislink/src/arcgislink_compiled.js"></script>');
// Setup Map Id
drupal_add_js(array('gmap_arcgis' => array('id' => $map['id'])), 'setting');