openlayers_layers_get_info

openlayers/openlayers.module, line 232

Versions
6
openlayers_layers_get_info($reset = FALSE)

Get Layer Info

Wrapper around layer info hook

Parameters

$reset Boolean whether to reset cache or not

Return value

array of layer info

Related topics

▾ 6 functions call openlayers_layers_get_info()

_openlayers_convert_map_to_form in openlayers/includes/openlayers.form.inc
OpenLayers Map to Form
_openlayers_convert_map_to_form in openlayers/includes/openlayers.form.inc
OpenLayers Map to Form
_openlayers_layers_process in openlayers/openlayers.module
Process Layers
_openlayers_layers_process in openlayers/openlayers.module
Process Layers
_openlayers_map_form in openlayers/includes/openlayers.form.inc
Get OpenLayers Form
_openlayers_map_form in openlayers/includes/openlayers.form.inc
Get OpenLayers Form

Code

<?php
function openlayers_layers_get_info($reset = FALSE) {
  static $info = array();
  
  // If empty or reset, get info
  if (count($info) == 0 || $reset == TRUE) {
    // Hook layer info ($map is not necessary)
    // hook_openlayers_layers_info($map = array())
    $info = module_invoke_all('openlayers_layers_info');
  }

  return $info;
}
?>