function ip_geoloc_views_post_render in IP Geolocation Views & Maps 7
Same name and namespace in other branches
- 8 ip_geoloc.module \ip_geoloc_views_post_render()
Implements hook_views_post_render().
Used to clear the 'is_updated' flag on the visitor location after any map Views have had the opportunity to respond to it being set.
File
- ./
ip_geoloc.module, line 947 - IPGV&M is a mapping engine for Views that contain locations of entities and/or visitors. Google Maps, Leaflet and OpenLayers2 maps are all supported. and available through this module. Using a number of optional sources IPGV&M also retrieves…
Code
function ip_geoloc_views_post_render(&$view, &$rendered_output) {
if (!isset($view) || !isset($view->style_plugin->plugin_name)) {
return;
}
$name = $view->style_plugin->plugin_name;
if (strpos($name, 'ip_geoloc') === 0 && ($location = ip_geoloc_get_visitor_location())) {
$location['is_updated'] = FALSE;
// This performs a merge.
_ip_geoloc_set_session_value('location', $location);
}
}