My below function that is copied from another function that works fine. Should get values from the query string and turn them into a date:
function updateShift()
{
echo $name = $_GET['shift_name'];
echo $start_date = date('Y-m-d H:i:s', strtotime("{$_GET['start_hours']}:{$_GET['start_minutes']} {$_GET['start_ampm']}"));
echo $stop_date = date('Y-m-d H:i:s', strtotime("{$_GET['stop_hours']}:{$_GET['stop_minutes']} {$_GET['stop_ampm']}"));
}
However it returns:
Shift Name
1969-12-31 17:00:00
1969-12-31 17:00:00
Any idea why this works fine elsewhere but not here? The query string is there as evidenced by the shift_name coming through correctly.