Home

About

Search

Copyright
$value) { $_GET[$key] = mysql_real_escape_string($value, $link); } // Count existing dates $query = " SELECT DISTINCT `local_day` FROM `ATS` ORDER BY `local_day` "; $query2 = " SELECT COUNT(DISTINCT `local_day`) FROM `ATS` LIMIT 0, 100 "; // Query $sqlResult = mysql_query($query2); $countDates = mysql_fetch_array($sqlResult, MYSQL_NUM); $countDates = $countDates[0]; $sqlResult = mysql_query($query); for ($i = 0; $i < $countDates; $i++) { $temp = mysql_fetch_array($sqlResult); $dates[$i] = convertDate($temp[0]); } // Parameters $reset = $_GET["reset"]; $submit = $_GET["submit"]; $listing = $_GET["listing"]; if ($listing == "") { $listing = "slides"; } /* If reset wasn't pressed, set each variable to the form input */ if ($reset != "Reset") { $localDay = $_GET["txtLocalDay1"]; $localDay_a = date("Y-m-d", strtotime($localDay)); $localDay2 = $_GET["txtLocalDay2"]; $localDay2_a = date("Y-m-d", strtotime($localDay2)); $gmtOp = $_GET["op1"]; $gmtBound = $_GET["selMeanTimeBound"]; $gmt = $_GET["txtMeanTime"]; $qualityOp = $_GET["op2"]; $quality = $_GET["selQuality"]; $locationsOp = $_GET["op3"]; for ($i = 1; $i <= 16; $i++) { $locParam = "loc" . $i; $locTemp[$i - 1] = $_GET["$locParam"]; if ($locTemp[$i - 1] != "") { $locations[$i] = $locTemp[$i - 1]; } } $numOfRecsPerPage = $_GET["numOfRecs"]; $ordering = $_GET["ordering"]; } // If reset was pressed, set each variable to default values else { $localDay = ""; $localDay2 = ""; $gmtOp = "AND"; $gmtBound = "none"; $gmt = ""; $qualityOp = "AND"; $quality = "none"; $locationsOp = "AND"; $j = 0; for ($i = 1; $i <= 15; $i++) { $locations[$i] = ""; } $numOfRecsPerPage = 12; $ordering = "time_asc"; $flag = true; } // Set up current page info if (isset($_GET["currPage"])) { $currPage = $_GET["currPage"]; } if ($currPage == "") { $currPage = 1; } echo "
"; $formURL = htmlentities($_SERVER['PHP_SELF']); ?>