You are here

public function GoogleUniversalAnalyticsService::buildConfigurationForm in Analytics 7

Form constructor.

Parameters

array $form: An associative array containing the initial structure of the plugin form.

array $form_state: The current state of the complete form.

Return value

array The form structure.

Overrides AnalyticsService::buildConfigurationForm

File

analytics_google/src/GoogleUniversalAnalyticsService.php, line 17

Class

GoogleUniversalAnalyticsService

Code

public function buildConfigurationForm($form, &$form_state) {
  $options['id'] = array(
    '#title' => t('Tracking ID'),
    '#type' => 'textfield',
    '#default_value' => $this
      ->getConfiguration()['id'],
    '#element_validate' => array(
      '_analytics_google_validate_id',
    ),
    '#required' => TRUE,
    '#size' => 15,
  );
  return $options;
}