I am trying to display the following select options. It displays a option value of all times during the day in 30 minute increments but I want the value to display the UTC time of that value.
$options = array(); $min30=array('00','30');
foreach (range(0,23) as $fullhour) {
$parthour = $fullhour > 12 ? $fullhour - 12 : $fullhour;
foreach($min30 as $int){
if($fullhour > 11){
echo "<option value='UTC TIME HERE'>".$options[$fullhour.".".$int]=$parthour.":".$int." PM</option>";
}else{
if($fullhour == 0){$parthour='12';}
echo "<option value='UTC TIME HERE'>".$options[$fullhour.".".$int]=$parthour.":".$int." AM</option>" ;
}
}
}
Can anyone give me any advice?