X-Git-Url: http://git.iain.cx/?a=blobdiff_plain;f=lib%2Ffunctions.php;h=eb48c4b75ada85a3ee21d79a75cb3653185627b2;hb=refs%2Ftags%2Fuat-2013-10-31;hp=a132ca1145704e363f195fd00ded4896d4848a9e;hpb=dcee8bacbf2d1eea4c00c42be7ce2dc14f113fa2;p=readifood.git diff --git a/lib/functions.php b/lib/functions.php index a132ca1..eb48c4b 100644 --- a/lib/functions.php +++ b/lib/functions.php @@ -428,9 +428,9 @@ function show_role_form($role, $roles) { for ($i = 0; $i < count($roles); $i++) { - echo " $roles[$i]\n"; + echo ">\n"; } } @@ -486,32 +486,8 @@ } function show_date_form($name, $date = null) { - $past = 60; - $future = 60; - echo "\n"; - return; - if (! isset($date)) $date = date('Y-m-d'); - list($y, $m, $d) = iso8601_to_ymd($date); - - echo "Year: "; - echo "Month: "; - echo "Day: "; + if (! isset($date)) $date = date('Y-m-d', time()); + datepicker($name, $date); } function validate_postcode($postcode, &$outward = null, &$inward = null) {