You are here

function getlocations_kml_form in Get Locations 7

Same name and namespace in other branches
  1. 7.2 getlocations.module \getlocations_kml_form()
1 call to getlocations_kml_form()
getlocations_map_display_options_form in ./getlocations.module
Function

File

./getlocations.module, line 4884
getlocations.module @author Bob Hutchinson http://drupal.org/user/52366 @copyright GNU GPL

Code

function getlocations_kml_form($defaults) {

  // KML
  $form = array();
  $form['kml_group'] = array(
    '#type' => 'fieldset',
    '#title' => t('Kml file'),
    '#description' => t('Attach a kml file.'),
    '#collapsible' => TRUE,
    '#collapsed' => empty($defaults['kml_group']['kml_url']) ? TRUE : FALSE,
    '#tree' => TRUE,
  );
  $form['kml_group']['kml_url'] = getlocations_element_map_tf(t('Kml url'), $defaults['kml_group']['kml_url'], t('A full url to a publicly accessible kml file.'));
  $form['kml_group']['kml_url_click'] = getlocations_element_map_checkbox(t('Kml layer clickable'), $defaults['kml_group']['kml_url_click']);
  $form['kml_group']['kml_url_infowindow'] = getlocations_element_map_checkbox(t('Suppress Kml layer InfoWindows'), $defaults['kml_group']['kml_url_infowindow']);
  $form['kml_group']['kml_url_viewport'] = getlocations_element_map_checkbox(t('Preserve viewport'), $defaults['kml_group']['kml_url_viewport']);
  $form['kml_group']['kml_url_button'] = getlocations_element_map_checkbox(t('Show toggle button'), $defaults['kml_group']['kml_url_button']);
  $form['kml_group']['kml_url_button_label'] = getlocations_element_map_tf(t('Label for toggle button'), $defaults['kml_group']['kml_url_button_label'], '', 30);
  $form['kml_group']['kml_url_button_state'] = getlocations_element_map_checkbox(t('Activate Kml layer'), $defaults['kml_group']['kml_url_button_state'], t('Activate Kml layer when map is first displayed.'));
  return $form;
}