From d2d66382e21774999fc2f39c2d6fb03cc2fb1a03 Mon Sep 17 00:00:00 2001 From: Markus Birth Date: Wed, 25 May 2016 16:58:13 +0200 Subject: [PATCH] Prepare input handling. --- index.php | 7 +++++++ templates/hotel_html.mustache | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/index.php b/index.php index b7aee28..2d81be8 100644 --- a/index.php +++ b/index.php @@ -48,6 +48,10 @@ if (isset($_GET['action'])) { $tpl = $m->loadTemplate('faq_html'); $tpl_done = true; break; + case 'send': + $form_type = $_POST['form_type']; + // TODO: Store form data in session + break; } } @@ -90,6 +94,9 @@ if (!$tpl_done && isset($_SESSION['access_token']) && $_SESSION['access_token']) $tpl_done = true; } else { switch ($_GET['action']) { + case 'send': + echo "This would send the mail..."; + break; case 'event': $tpl = $m->loadTemplate('event_html'); $tpl_done = true; diff --git a/templates/hotel_html.mustache b/templates/hotel_html.mustache index 62879d2..0a0a39d 100644 --- a/templates/hotel_html.mustache +++ b/templates/hotel_html.mustache @@ -8,7 +8,8 @@

hotel Hotel Reservation

-
+ + {{#form_data}}

{{group_name}}

@@ -17,7 +18,6 @@ {{>mdl_input}} {{/fields}} - {{/form_data}}