Advertisement
Guest User

Untitled

a guest
May 24th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. <?php
  2. class RRShopCheckoutControllerExtension extends DataExtension {
  3. public function updateCheckoutForm($form) {
  4. $text = ShopConfig::current_shop_config()->DSGVOCheckoutText;
  5. if ($text) {
  6. $fields = $form->Fields();
  7. $validator = $form->getValidator();
  8. $fields->push(CheckboxField::create('DSGVO', $text));
  9. $validator->addRequiredField('DSGVO');
  10. }
  11. }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement