public function SimpleAdSenseBlock::blockForm in Simple AdSense 8.0
Same name and namespace in other branches
- 1.0.x src/Plugin/Block/SimpleAdSenseBlock.php \Drupal\simple_adsense\Plugin\Block\SimpleAdSenseBlock::blockForm()
Overrides BlockPluginTrait::blockForm
File
- src/
Plugin/ Block/ SimpleAdSenseBlock.php, line 21
Class
- SimpleAdSenseBlock
- Provides a 'SimpleAdSenseBlock' block.
Namespace
Drupal\simple_adsense\Plugin\BlockCode
public function blockForm($form, FormStateInterface $form_state) {
$form['slot'] = array(
'#type' => 'textfield',
'#title' => $this
->t('Ad Unit Id'),
'#description' => $this
->t('Unique Responsive Ad Unit Id. eg: 5556618763'),
'#default_value' => isset($this->configuration['slot']) ? $this->configuration['slot'] : '',
'#maxlength' => 64,
'#size' => 64,
'#weight' => '10',
);
return $form;
}