That was the result I was looking for, thanks for your help.
<?php
date_default_timezone_set('Europe/Istanbul');
$baslangic = strtotime("2019-11-13 00:10:00");
$bitis = strtotime("2019-11-13 01:00:00");
$simdi = time();
if ($simdi < $baslangic) {
$percentage = 0;
} else if ($simdi > $bitis) {
$percentage = 100;
}else {
$percentage = ($baslangic - $simdi) * 100 / ($baslangic - $bitis);
}
echo round($percentage,2);
?>
1
solved do I calculate the percentage of two hours?