nicemap/nicemap.theme.inc, line 65
- Versions
- 6
_theme_nicemap_map_full($points, $map, $options)
Code
<?php
function _theme_nicemap_map_full($points, $map, $options) {
$w = $options['width'] .'px';
$h = $options['height'] .'px';
$map_url = $map->url($options);
if ($map_url) {
$map_bg = "background-image:url('$map_url');";
}
// use a hardcoded index to associate point to item
$i = 0;
foreach ($points as $point) {
$point['i'] = $i;
$geopoints .= theme('nicemap_point', $point);
$geocontent .= theme('nicemap_content', $point);
$i++;
}
$attr = array(
"class" => "nicemap-map",
"style" => "$map_bg width:$w; height:$h;",
);
$attr = drupal_attributes($attr);
return "
<div $attr>
$geopoints
<div class='hidden'>$geocontent</div>
</div>
";
}
?> 