Skip to content

Commit

Permalink
DEBUG demo
Browse files Browse the repository at this point in the history
  • Loading branch information
mvorisek committed Feb 25, 2022
1 parent 1f755af commit 8208cab
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions demos/basic/button.php
Original file line number Diff line number Diff line change
Expand Up @@ -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 <[email protected]>']
);
$form->onSubmit(function () use ($form) {
echo '<pre>';
echo htmlspecialchars(
print_r($form->model->get(), true)
);
});

// With Seed
Button::addTo($app, ['Click me'])->link(['index']);

Expand Down

0 comments on commit 8208cab

Please sign in to comment.