Skip to content

Commit

Permalink
Some modifications to make mandatory multiple options work
Browse files Browse the repository at this point in the history
git-svn-id: file:///Users/Shitiz/Downloads/lssvn/trunk/unstable@850 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
jcleeland committed Jan 29, 2004
1 parent 61390e2 commit 624976e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions group.php
Expand Up @@ -125,7 +125,7 @@
$mi=0;
foreach ($chkcmands as $ccm)
{
if ($multiname != "MULTI$cmfns[$mi]") //the last multipleanswerchecked is different to this one
if (!isset($multiname) || $multiname != "MULTI$cmfns[$mi]") //the last multipleanswerchecked is different to this one
{
if (isset($multiname) && $multiname && isset($_POST[$multiname]) && $_POST[$multiname])
{
Expand All @@ -141,13 +141,14 @@
}
}
$multiname="MULTI$cmfns[$mi]";
$multiname2=$multiname."2"; //POSSIBLE CORRUPTION OF PROCESS - CHECK LATER
$$multiname=0;
$$multiname2=0;
}
else{$multiname="MULTI$cmfns[$mi]";}
$dccm="display$cmfns[$mi]";
//if (($_SESSION[$ccm] == "0" || $_SESSION[$ccm]) && $_POST[$dccm] == "on")//There is an answer
if (isset($_SESSION[$ccm]) && isset($_POST[$dccm]) && $_POST[$dccm] == "on")
if (isset($_SESSION[$ccm]) && $_SESSION[$ccm] && isset($_POST[$dccm]) && $_POST[$dccm] == "on")
{
}
elseif ($_POST[$dccm] == "on" && (!isset($_POST[$multiname]) || !$_POST[$multiname])) //Question is on, there is no answer, but it's a multiple
Expand Down

0 comments on commit 624976e

Please sign in to comment.