From b519726d73ffed79dc98ace17e39242f59aab4e1 Mon Sep 17 00:00:00 2001 From: james Date: Sun, 27 Mar 2011 17:11:36 +0000 Subject: [PATCH] Update website consent page --- admin/registration_webconsent.php | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/admin/registration_webconsent.php b/admin/registration_webconsent.php index 2f6b6a9..f7abb90 100644 --- a/admin/registration_webconsent.php +++ b/admin/registration_webconsent.php @@ -34,18 +34,15 @@ echo "
"; - if(is_array($_POST['changed'])) - { + if(is_array($_POST['changed'])) { $numchanged=0; - foreach($_POST['changed'] AS $id=>$val) - { - if($val==1) - { + foreach($_POST['changed'] AS $id=>$val) { + if($val==1) { $numchanged++; $webfirst=$_POST['webfirst'][$id]=="yes"?"yes":"no"; $weblast=$_POST['weblast'][$id]=="yes"?"yes":"no"; $webphoto=$_POST['webphoto'][$id]=="yes"?"yes":"no"; - mysql_query("UPDATE students SET + mysql_query("UPDATE users SET webfirst='$webfirst', weblast='$weblast', webphoto='$webphoto' @@ -71,24 +68,24 @@