Closed (fixed)
Project:
GMap + Geo
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
9 Jun 2009 at 04:33 UTC
Updated:
26 Jun 2009 at 16:20 UTC
As of tonight, you should be defining 'array' (or whatever you want, per #483936 ) in hook_field_formatter_info()
OLD:
function gmap_geo_field_formatter_info() {
return array(
'gmap_geo' => array(
'label' => t('GMap'),
'field types' => array('geo', 'geo_data'),
'multiple values' => CONTENT_HANDLE_MODULE,
),
);
}
NEW
function gmap_geo_field_formatter_info() {
return array(
'gmap_geo' => array(
'label' => t('GMap'),
'field types' => array('geo', 'geo_data'),
'multiple values' => CONTENT_HANDLE_MODULE,
'gis types' => array('point', 'linestring', 'polygon'),
'gis input' => 'array'
),
);
}
You can remove any calls to geo_wkb_get_data() and simply expect $element['#item'][$delta]['array'] to exist. The on-the-fly conversion is managed by hook_nodeapi:view.
Comments
Comment #1
becw commentedThis isn't working for me... I'm using the exact code you have under "new".
Comment #2
becw commentedThis was not working because of an issue with geo_data, which has been fixed with http://drupal.org/cvs?commit=224072
I have now committed this change -- http://drupal.org/cvs?commit=224590