summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrandon Bergren2008-09-30 18:07:16 (GMT)
committer Brandon Bergren2008-09-30 18:07:16 (GMT)
commitbe7cdd73aa6ce6ae9e6890573658f2ca6636b279 (patch)
tree9884738f67589b55f409de744c800567f23caa27
parent097c05138c13c747cf4c8ff3de8e3d2687ce3aea (diff)
#279049 reported by tormi: Use a valid variable for the author map marker. (You can now choose a marker by going to "configure" for the author map block.)
-rw-r--r--gmap_location.module10
1 files changed, 9 insertions, 1 deletions
diff --git a/gmap_location.module b/gmap_location.module
index cbd00c5..f82a4d7 100644
--- a/gmap_location.module
+++ b/gmap_location.module
@@ -667,6 +667,12 @@ function gmap_location_block($op = 'list', $delta = 0, $edit = array()) {
'#options' => array_map('check_plain', node_get_types('names')),
'#default_value' => variable_get('gmap_location_author_block_types', array()),
);
+
+ $form['gmap_location_author_block_marker'] = array(
+ '#type' => 'gmap_markerchooser',
+ '#title' => t('Marker to use for author map'),
+ '#default_value' => variable_get('gmap_location_author_block_marker', 'drupal'),
+ );
}
return $form;
@@ -711,6 +717,8 @@ function gmap_location_block($op = 'list', $delta = 0, $edit = array()) {
// Save "enabled on" types.
variable_set('gmap_location_author_block_types', array_keys(array_filter($edit['gmap_location_author_block_types'])));
+ // Save marker.
+ variable_set('gmap_location_author_block_marker', $edit['gmap_location_author_block_marker']);
}
return;
@@ -797,7 +805,7 @@ function gmap_location_author_block_view($nid) {
$map['#settings']['markers'][] = array(
'latitude' => $result['latitude'],
'longitude' => $result['longitude'],
- 'markername' => variable_get('gmap_user_map_marker', 'drupal'),
+ 'markername' => variable_get('gmap_location_author_block_marker', 'drupal'),
'label' => check_plain($node->name),
);
$map['#settings']['latitude'] = $result['latitude'];