Skip to content

Commit

Permalink
Warnings and Notices cleanup
Browse files Browse the repository at this point in the history
git-svn-id: file:///Users/Shitiz/Downloads/lssvn/trunk/unstable@800 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
jcleeland committed Dec 6, 2003
1 parent a67541e commit fc8bd33
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 34 deletions.
12 changes: 6 additions & 6 deletions group.php
Expand Up @@ -704,7 +704,7 @@
echo "\t<!--\n";
echo "\t\tfunction checkconditions(value, name, type)\n";
echo "\t\t\t{\n";
if (is_array($conditions))
if (isset($conditions) && is_array($conditions))
{
if (!isset($endzone)) {$endzone="";}
echo "\t\t\tif (type == 'radio')\n";
Expand Down Expand Up @@ -769,11 +769,11 @@
}
$java .= $endzone;
}
echo $java;
echo "\t\t\t}\n";
echo "\t//-->\n";
echo "\t</script>\n\n";
echo "\n\n<!-- START THE GROUP -->\n";
if (isset($java)) {echo $java;}
echo "\t\t\t}\n"
."\t//-->\n"
."\t</script>\n\n"
."\n\n<!-- START THE GROUP -->\n";
foreach(file("$thistpl/startgroup.pstpl") as $op)
{
echo "\t".templatereplace($op);
Expand Down
56 changes: 28 additions & 28 deletions survey.php
Expand Up @@ -653,29 +653,29 @@
}
echo "\n<form method='post' action='{$_SERVER['PHP_SELF']}' id='phpsurveyor' name='phpsurveyor'>\n";
//PUT LIST OF FIELDS INTO HIDDEN FORM ELEMENT
echo "\n\n<!-- INPUT NAMES -->\n";
echo "\t<input type='hidden' name='fieldnames' value='";
echo implode("|", $inputnames);
echo "'>\n";
echo "\n\n<!-- INPUT NAMES -->\n"
."\t<input type='hidden' name='fieldnames' value='"
.implode("|", $inputnames)
."'>\n";

foreach(file("$thistpl/welcome.pstpl") as $op)
{
echo templatereplace($op);
}

echo "\n\n<!-- JAVASCRIPT FOR CONDITIONAL QUESTIONS -->\n";
echo "\t<script type='text/javascript'>\n";
echo "\t<!--\n";
echo "\t\tfunction checkconditions(value, name, type)\n";
echo "\t\t\t{\n";
if (is_array($conditions))
echo "\n\n<!-- JAVASCRIPT FOR CONDITIONAL QUESTIONS -->\n"
."\t<script type='text/javascript'>\n"
."\t<!--\n"
."\t\tfunction checkconditions(value, name, type)\n"
."\t\t\t{\n";
if (isset($conditions) && is_array($conditions))
{
if (!isset($endzone)) {$endzone="";}
echo "\t\t\tif (type == 'radio')\n";
echo "\t\t\t\t{\n";
echo "\t\t\t\tvar hiddenformname='java'+name;\n";
echo "\t\t\t\tdocument.getElementById(hiddenformname).value=value;\n";
echo "\t\t\t\t}\n";
echo "\t\t\tif (type == 'radio')\n"
."\t\t\t\t{\n"
."\t\t\t\tvar hiddenformname='java'+name;\n"
."\t\t\t\tdocument.getElementById(hiddenformname).value=value;\n"
."\t\t\t\t}\n";
$java="";
$cqcount=1;
foreach ($conditions as $cd)
Expand Down Expand Up @@ -716,16 +716,16 @@
}
if ((isset($oldq) && $oldq != $cd[0]) || !isset($oldq))//Close if statement
{
$endzone = "))\n";
$endzone .= "\t\t\t\t{\n";
$endzone .= "\t\t\t\tdocument.getElementById('$cd[0]').style.display='';\n";
$endzone .= "\t\t\t\tdocument.getElementById('display$cd[0]').value='on';\n";
$endzone .= "\t\t\t\t}\n";
$endzone .= "\t\t\telse\n";
$endzone .= "\t\t\t\t{\n";
$endzone .= "\t\t\t\tdocument.getElementById('$cd[0]').style.display='none';\n";
$endzone .= "\t\t\t\tdocument.getElementById('display$cd[0]').value='';\n";
$endzone .= "\t\t\t\t}\n";
$endzone = "))\n"
. "\t\t\t\t{\n"
. "\t\t\t\tdocument.getElementById('$cd[0]').style.display='';\n"
. "\t\t\t\tdocument.getElementById('display$cd[0]').value='on';\n"
. "\t\t\t\t}\n"
. "\t\t\telse\n"
. "\t\t\t\t{\n"
. "\t\t\t\tdocument.getElementById('$cd[0]').style.display='none';\n"
. "\t\t\t\tdocument.getElementById('display$cd[0]').value='';\n"
. "\t\t\t\t}\n";
$cqcount++;
}
$oldq = $cd[0]; //Update oldq for next loop
Expand All @@ -734,9 +734,9 @@
$java .= $endzone;
}
echo $java;
echo "\t\t\t}\n";
echo "\t//-->\n";
echo "\t</script>\n\n";
echo "\t\t\t}\n"
."\t//-->\n"
."\t</script>\n\n";

foreach ($_SESSION['grouplist'] as $gl)
{
Expand Down

0 comments on commit fc8bd33

Please sign in to comment.