you can now set if a station needs points or get the results of the excersice and the website should calculate the points
This commit is contained in:
@@ -8,7 +8,8 @@
|
||||
if(isset($_POST['save'])){
|
||||
$station_name = sanitize_input($_POST['station_name']);
|
||||
$station_pos = sanitize_input($_POST['station_pos']);
|
||||
write_station($con, $station_name, $station_pos);
|
||||
$station_direct_points = sanitize_input($_POST['direkte_punkte']);
|
||||
write_station($con, $station_name, $station_pos, $station_direct_points);
|
||||
}
|
||||
header("Location: stationen.php");
|
||||
die;
|
||||
@@ -34,6 +35,13 @@
|
||||
<span></span>
|
||||
<label for="station_pos">Standort</label>
|
||||
</div>
|
||||
<div class="dropdown">
|
||||
<label for="direkte_punkte">Punkte eintragen</label>
|
||||
<select name="direkte_punkte" id="direkte_punkte">
|
||||
<option value="1" selected>Ja</option>
|
||||
<option value="0">Nein</option>
|
||||
</select>
|
||||
</div>
|
||||
<input id="button" type="submit" value="Hinzufügen" class="btn-confirm" name="save"/>
|
||||
<a href="stationen.php" class="btn-close">Schließen</a>
|
||||
</form>
|
||||
|
||||
Reference in New Issue
Block a user