Invalid argument supplied for foreach() in gmap_addons/gmap_cck.module on line 517.
hecatomber - November 1, 2008 - 23:24
| Project: | GMap Addons |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | support request |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Description
When I set an existing node_reference field on the gmap cck field, I'm getting this error.
And that line refers to the first line of this code;
<?php
>
foreach ($nrf as $delta => $item) {
if (!empty($item['nid']) && is_numeric($item['nid'])) {
$nids[] = $item['nid'];
$n = node_load($item['nid']);
if ($n) {
$settings['markers'][] = array(
'label' => $n->title,
'opts' => array('title' => $n->title),
'latitude' => $n->locations[0]['latitude'],
'longitude' => $n->locations[0]['longitude'],
'markername' => variable_get('gmap_node_marker_'. $n->type, 'drupal'),
'text' => theme('gmapnodelabel', $n), // TODO:
//'popuplink' => url('map/query/node/'. $n->nid),
);
}
}
?>