as posted by bec in http://drupal.org/node/437588
#####################################
well, it looks like the imagefield cck field type is "filefield", while the Geocode module expects it to be "imagefield". This should be changed on line 18 of geocode/includes/modules/imagefield.inc:
/**
* Implementation of hook_geocode_handler_info() on behalf of imagefield.
*/
function imagefield_geocode_handler_info() {
$handlers = array();
// This functionality requires PHP's exif module
if (function_exists('exif_read_data')) {
$handlers['geocode_imagefield'] = array(
'title' => t('Image field'),
'module' => 'geocode',
'file' => 'imagefield.inc',
'file path' => drupal_get_path('module', 'geocode') .'/includes/modules',
'return types' => array(
'geo' => array('point'),
),
'field types' => array('imagefield'), // <-- should be 'filefield'
);
}
return $handlers;
}
I can confirm that changing this line does fix the issue and pictures uploaded into an imagefield will now get geocoded
Comments
Comment #1
becw commented@ansorg -- thanks for posting this over here!
I can confirm that this fix works, of course :)
Comment #2
wisu commented@ansorg
This solution enabled the Image field option of the Geocode Handle:
but the Return value: option still shows linestring... is there anything else to do to change it?
Thanks
Comment #3
allie mickaWe've been successfully using Geocode to manage photos for awhile now, and that described fix has been in the code for . I suspect that this is working in HEAD, and I'll tag a release appropriately to get around #557096