function _openlayers_render_debug_map in Openlayers 6
Debug Map
Offers debugging if enabled. Options are available in the administration interface to enable different kinds of debugging at different points of rendering.
Parameters
$op: The operation that is getting carried out
$map: map array to debug
Return value
none
1 call to _openlayers_render_debug_map()
- openlayers_render_map in ./
openlayers.module - Render Map
File
- includes/
openlayers.render.inc, line 249 - This file holds the functions the extra processing of rendering a map
Code
function _openlayers_render_debug_map($op = NULL, $map = array()) {
// Check op
switch ($op) {
case 'pre-render':
// Screen output, check function first
if (function_exists('dpm')) {
if (variable_get('openlayers_debug_screen_pre_render', FALSE)) {
dpm($map);
}
}
// Check watchdog
if (variable_get('openlayers_debug_watchdog_pre_render', FALSE)) {
watchdog('openlayers', '<p>Pre render output.</p><pre>!array_output</pre>', array(
'!array_output' => var_export($map, TRUE),
), WATCHDOG_DEBUG);
}
break;
case 'post-render':
// Screen output, check function first
if (function_exists('dpm')) {
if (variable_get('openlayers_debug_screen_post_render', FALSE)) {
dpm($map);
}
}
// Check watchdog
if (variable_get('openlayers_debug_watchdog_post_render', FALSE)) {
watchdog('openlayers', '<p>Post render output.</p><pre>!array_output</pre>', array(
'!array_output' => var_export($map, TRUE),
), WATCHDOG_DEBUG);
}
break;
}
}