public function AmpTrackingPixelAnalyticsService::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_amp/
src/ AmpTrackingPixelAnalyticsService.php, line 17
Class
Code
public function buildConfigurationForm($form, &$form_state) {
$options['url'] = array(
'#title' => t('URL'),
'#type' => 'urlfield',
'#default_value' => $this
->getConfiguration()['url'],
'#description' => t('See the <a href="@url">substitutions guide</a> to see what variables can be included in the URL.', array(
'@url' => 'https://github.com/ampproject/amphtml/blob/master/spec/amp-var-substitutions.md',
)),
'#required' => TRUE,
'#placeholder' => 'https://foo.com/pixel?RANDOM',
);
return $options;
}