function openlayers_layer_type_cloudmade::options_form in Openlayers 6.2
Same name and namespace in other branches
- 7.2 plugins/layer_types/openlayers_layer_type_cloudmade.inc \openlayers_layer_type_cloudmade::options_form()
Options form which generates layers
Overrides openlayers_layer_type::options_form
File
- includes/
layer_types/ cloudmade.inc, line 38 - OpenLayers CloudMade layer type
Class
- openlayers_layer_type_cloudmade
- OpenLayers CloudMade Layer Type class
Code
function options_form() {
$warning = !variable_get('openlayers_layers_cloudmade_js', FALSE) || !variable_get('openlayers_layers_cloudmade_api', FALSE) ? array(
'#value' => t('WARNING: Your CloudMade API key or
Javascript location is not set. Map including CloudMade layers
will break until they are set correctly.'),
) : NULL;
return array(
'styleId' => array(
'#type' => 'textfield',
'#title' => t('Style ID'),
'#description' => t('Enter the numeric Style ID for a <a href="http://maps.cloudmade.com/editor">Map Style</a> from CloudMade. You can usually find the Style ID in the lower right hand corner of each Map Style box.'),
'#default_value' => isset($this->data['styleId']) ? $this->data['styleId'] : '',
),
'layer_type' => array(
'#type' => 'hidden',
'#value' => 'openlayers_layer_type_cloudmade',
),
$warning,
);
}