Merge pull request #456 from Struart88/patch-2
[FlightAirMap.git] / date.php
blobb73a28d0c83f4b667f769e269a879889e3d866d5
1 <?php
2 require_once(dirname(__FILE__).'/require/settings.php');
3 $type = 'aircraft';
4 if (isset($_GET['marine'])) $type = 'marine';
5 elseif (isset($_GET['tracker'])) $type = 'tracker';
6 $date = filter_input(INPUT_POST,'date',FILTER_SANITIZE_STRING);
7 if ($date == '') $date = date('Y-m-d');
8 if ($type == 'marine') header('Location: '.$globalURL.'/marine/date/'.$date);
9 elseif ($type == 'tracker') header('Location: '.$globalURL.'/tracker/date/'.$date);
10 else header('Location: '.$globalURL.'/date/'.$date);