First Push

This commit is contained in:
Christian Kagerbauer 2023-07-19 12:11:08 +02:00
parent 545691d7bd
commit c82451d4b6

26
index.php Normal file
View file

@ -0,0 +1,26 @@
<?php
require_once 'vendor/autoload.php';
$form = new Formr\Formr('bootstrap');
$form->required = '*';
if ($form->submitted())
{
// get our form values and assign them to a variable
$data = $form->validate('Vorname, Name');
// show a success message if no errors
if($form->ok()) {
$form->success_message = "Thank you, {$data['name']}!";
}
}
?>
<!DOCTYPE html>
<html lang="en">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.1/css/bulma.min.css">
<body class="container">
<?php
$form->messages();
$form->create_form('Firma, Vorname, Name, Strasse, PLZ, Ort, Email, Stundenlohn, Comments|textarea');
?>
</body>
</html>