Put the select code blocks inside the form, so that it can be submitted.
PHP Forms[
^]
<form id="form1" name="form1" method="post" action="includes/bookingProjectIndex.php">
<!— other HTML code —>
<?php
$sql = "SELECT * FROM (event_types)";
$query = mysqli_query ($link,$sql);
echo "Select an event type:<select name='event_type'>";
while ($result = mysqli_fetch_array($query, MYSQL_ASSOC)){
echo "<option value='" .$result['event_type']."'>" . $result['event_type'] . "</option>";
}
echo "</select>";
echo "<br></br>";
$sqlt = "SELECT * FROM (facilities)";
$queryt = mysqli_query ($link,$sqlt);
echo "Select a facility to host event:<select name='name_of_facility'>";
while ($resultt = mysqli_fetch_array($queryt, MYSQL_ASSOC)){
echo "<option value='" .$resultt['name_of_facility']."'>" . $resultt['name_of_facility'] . "</option>";
}
echo "</select>";
echo "<br></br>";
?>
<input type="submit" name="Submit> value="Submit">
</form>
However, you should use parameterized query to avoid SQL injection, refer:
1.
SQL Injection[
^]
2.
How can I prevent SQL-injection in PHP?[
^]