From b9e03f62efbfd55764872f49cd58c84384f33e2b Mon Sep 17 00:00:00 2001 From: mauirixxx Date: Tue, 30 May 2017 16:34:15 -1000 Subject: [PATCH] maybe the array thing isn't the right way to go --- gw-create.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gw-create.php b/gw-create.php index 71aa505..66bd07f 100644 --- a/gw-create.php +++ b/gw-create.php @@ -16,10 +16,10 @@ if ($createnew === "1"){ $bdate = mysqli_real_escape_string($con, $_POST['bdate']); $profid = mysqli_real_escape_string($con, $_POST['professionid']); function getColor() { - return array("#DDD", "#FF8", "#CF9", "#ACF", "#9FC", "#DAF", "#FBB", "#FCE", "#BFF", "#FC9", "#DDF"); + return array("#FFF", "#DDD", "#FF8", "#CF9", "#ACF", "#9FC", "#DAF", "#FBB", "#FCE", "#BFF", "#FC9", "#DDF"); } $profcolor = getColor()[$profid]; - echo 'profession color is ' . $profcolor . '!'; + echo 'profession color is ' . $profcolor . ' due to profid being ' . $profid . '!'; list ($y, $m, $d) = explode('-', $bdate); if (!checkdate($m, $d, $y)) { echo 'Date is invalid ' . $bdate . '
';