I used Datepicker a few times and always transmitted data with GET. Now I'm trying to use it with POST. Here is my HTML CODE:
<div class="input-group date" name="eintritt" id="datetimepicker_benutzer_detail_start">
<input type="text" class="form-control" />
<span class="input-group-addon">
<span class="glyphicon glyphicon-calendar"></span>
</span>
</div>
And here is my JavaScript:
$(function () {
$('#datetimepicker_benutzer_detail_start').datetimepicker({
defaultDate: '2018/01/01',
format: 'DD.MM.YYYY',
locale: 'de'
});
Now my question: There is a formular with some text fields and those are sent via POST and stored in a MYSQL table. But how is it possible to get the shown date from the Datepicker? It's not possible with $_POST['eintritt']...
My form tag looks like this:
<form id="benutzer_daten" name="benutzer_daten" method="post" action="<?php echo $_SERVER['REQUEST_URI'];?>">
And the I just get the POST values like this:
$vorname = $_POST['vorname'];
$nachname = $_POST['nachname'];
And after there is a normal mysql insert...