0) { $row = mysql_fetch_array($result); $UserID = $row["UserID"]; } } if (NorthAmerica()) { $DateFormat = "%m/%d/%y"; } else { $DateFormat = "%d/%m/%y"; } $CurrentTime = mktime(); $query = "SELECT DiaryID, Venue, Type, DATE_FORMAT(DiaryDate,'$DateFormat') AS FormatedDiaryDate, Description FROM Diary " ."WHERE UserID='$UserID' AND UNIX_TIMESTAMP(DiaryDate) >= $CurrentTime" ." ORDER BY DiaryDate"; // Find the user in the database $result = mysql_query($query,$connection); $num_results = mysql_num_rows($result); if ($num_results > 0) { $breeder_diary_list_array = array(); $num_breeder_diary_list_results = $num_results; for ($count=0;$count<$num_results;$count++) { $row = mysql_fetch_array($result); $breeder_diary_list_array [$count] = $row; } session_register("breeder_diary_list_array"); session_register("num_breeder_diary_list_results"); $HTTP_SESSION_VARS["breeder_diary_list_array"] = $breeder_diary_list_array; $HTTP_SESSION_VARS["num_breeder_diary_list_results"] = $num_breeder_diary_list_results; header("Location: DisplayBreederDiaryList.php?Direct=$Direct&BreederID=$BreederID&PHPSESSID=$sessionid"); } else { LanuageKeywords(); if ($Direct) { do_html_header("Diary Dates"); echo $langKw["nocurrentdiarydates"]; echo"
"; } else { include ('header.php'); htmlheader($langKw["saleanimals"]); echo "
"; echo "

"; echo $langKw["diarydatesfor"]; echo "


"; echo "

"; echo $langKw["nocurrentdiarydates"]; echo "

"; do_html_footer(); echo "
"; include ('footer.php'); } } } ?>