From 8208cab796e00b5a16c9da80358d46f33b9c1914 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vo=C5=99=C3=AD=C5=A1ek?= Date: Fri, 25 Feb 2022 18:30:55 +0100 Subject: [PATCH] DEBUG demo --- demos/basic/button.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/demos/basic/button.php b/demos/basic/button.php index 0577f14d80..12e2ede98f 100644 --- a/demos/basic/button.php +++ b/demos/basic/button.php @@ -16,6 +16,22 @@ \Atk4\Ui\Header::addTo($app, ['Basic Button', 'size' => 2]); +$form = \Atk4\Ui\Form::addTo($app); +$recipient = $form->addControl( + 'recipient', + [\Atk4\Ui\Form\Control\Dropdown::class, + 'isMultiple' => true, + 'dropdownOptions' => ['allowAdditions' => true, 'forceSelection' => false], + ], + ['default' => 'Username '] +); +$form->onSubmit(function () use ($form) { + echo '
';
+    echo htmlspecialchars(
+        print_r($form->model->get(), true)
+    );
+});
+
 // With Seed
 Button::addTo($app, ['Click me'])->link(['index']);