From 952a4d3c29e80745df3b111c3637be6e3d5154bf Mon Sep 17 00:00:00 2001 From: james Date: Fri, 9 Feb 2007 14:57:07 +0000 Subject: [PATCH] Fix a bug where if no $table is passed to addTable it will now return gracefully instead of spitting out error messages Add email field to the judge list, and the judge manager list --- admin/judges_judges.php | 3 +++ judge.class.php | 1 + lpdf.php | 3 +++ 3 files changed, 7 insertions(+) diff --git a/admin/judges_judges.php b/admin/judges_judges.php index 127e02cf..f49e7f47 100644 --- a/admin/judges_judges.php +++ b/admin/judges_judges.php @@ -63,6 +63,7 @@ function openjudgeinfo(id) judges.id, judges.firstname, judges.lastname, + judges.email, judges.complete, judges_years.year @@ -84,6 +85,7 @@ function openjudgeinfo(id) echo mysql_error(); echo ""; echo " ".i18n("Judge Name").""; + echo " ".i18n("Email Address").""; echo " ".i18n("Active").""; echo " ".i18n("Complete").""; echo " ".i18n("Actions").""; @@ -95,6 +97,7 @@ function openjudgeinfo(id) echo ""; echo "id)\">$r->firstname $r->lastname"; echo ""; + echo "$r->email"; if($r->year) { echo "".i18n("yes").""; diff --git a/judge.class.php b/judge.class.php index 7933cd5a..3a36628c 100644 --- a/judge.class.php +++ b/judge.class.php @@ -29,6 +29,7 @@ $judges_fields = array( 'firstname' => 'First Name', $judges_table_fields = array( 'id' => 'ID', 'firstname' => 'First Name', 'lastname' => 'Last Name', + 'email' => 'Email Address', 'complete' => 'Complete', // 'year' => 'Year', ); diff --git a/lpdf.php b/lpdf.php index 7bf4f596..b85a151b 100644 --- a/lpdf.php +++ b/lpdf.php @@ -521,6 +521,9 @@ class lpdf function addTable($table,$align="center") { + //if we get a table passed in that doesnt look like a table (not an array) then just return doing nothing + if(!is_array($table)) return; + if(is_array($table['header'])) { $table_cols=count($table['header']);