I'm using eonasdan Datetimepicker in my project but I can't really set the value that I'm getting from my DB in the input field
here is my HTML code
<div class="form-group">
<label class="col-sm-2 col-form-label">Conference start</label>
<div class='col-sm-10'>
<input type='text' class="form-control" id='datetimepicker4' name="datestart" value="<?=$vars['tstart']?>" />
</div>
</div>
here is my JS code
$(function () {
$('#datetimepicker4').datetimepicker({
daysOfWeekDisabled: [0],
format: 'YYYY-MM-DD H:mm'
});
});
from my MYSQL DB, I get the DATETIME in the variable $VAR but in the input field I always have the "2020-04-04 00:00" when it's supposed to be "2020-04-09 02:35"
if I inspect element using google chrome tools in the input value I see the correct date but in the field, I get the wrong DATETIME