From b8e4c38c2be646286bedcd7306f65a6765aae9e6 Mon Sep 17 00:00:00 2001 From: james Date: Thu, 25 Oct 2007 20:30:58 +0000 Subject: [PATCH] Make sure we have an ID and a Year before trying to make the report --- admin/reports_gen.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/admin/reports_gen.php b/admin/reports_gen.php index 3e2bd6f1..25fd6836 100644 --- a/admin/reports_gen.php +++ b/admin/reports_gen.php @@ -35,6 +35,10 @@ if($format == '') $format = NULL; - report_gen_by_id($id, $year, $format); - + if($id && $year) + report_gen_by_id($id, $year, $format); + else { + header("Location: reports.php"); + exit; + } ?>