Skip to content

Commit

Permalink
Bugfix: Fixed notices where error reporting is on (using isset checks…
Browse files Browse the repository at this point in the history
…).. also fixed updating flexible labels by column.

git-svn-id: file:///Users/Shitiz/Downloads/lssvn/trunk/unstable@998 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
jcleeland committed Apr 24, 2004
1 parent b42d79e commit 0e8c9b8
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions admin/dataentry.php
Expand Up @@ -895,7 +895,7 @@

while ($irow = mysql_fetch_array($iresult))
{
if ($irow['type'] != "Q" && $irow['type'] != "M" && $irow['type'] != "P" && $irow['type'] != "A" && $irow['type'] != "B" && $irow['type'] != "C" && $irow['type'] != "E" && $irow['type'] != "F" && $irow['type'] != "O" && $irow['type'] != "R")
if ($irow['type'] != "Q" && $irow['type'] != "M" && $irow['type'] != "P" && $irow['type'] != "A" && $irow['type'] != "B" && $irow['type'] != "C" && $irow['type'] != "E" && $irow['type'] != "F" && $irow['type'] != "H" && $irow['type'] != "O" && $irow['type'] != "R")
{
$fieldname = "{$irow['sid']}X{$irow['gid']}X{$irow['qid']}";
if (isset($_POST[$fieldname])) { $thisvalue=$_POST[$fieldname]; } else {$thisvalue="";}
Expand Down Expand Up @@ -1009,8 +1009,8 @@
}
}
$updateqr = substr($updateqr, 0, -3);
if ($_POST['datestamp']) {$updateqr .= ", datestamp='{$_POST['datestamp']}'";}
if ($_POST['token']) {$updateqr .= ", token='{$_POST['token']}'";}
if (isset($_POST['datestampe']) && $_POST['datestamp']) {$updateqr .= ", datestamp='{$_POST['datestamp']}'";}
if (isset($_POST['token']) && $_POST['token']) {$updateqr .= ", token='{$_POST['token']}'";}
$updateqr .= " WHERE id=$id";
$updateres = mysql_query($updateqr) or die("Update failed:<br />\n" . mysql_error() . "\n<pre style='text-align: left'>$updateqr</pre>");
echo "<font color='green'><b>"._SUCCESS."</b></font><br />\n"
Expand Down Expand Up @@ -1601,6 +1601,7 @@
echo "</table>\n";
break;
case "F": //ARRAY (Flexible Labels)
case "H":
$meaquery = "SELECT * FROM {$dbprefix}answers WHERE qid={$deqrow['qid']} ORDER BY sortorder, answer";
$mearesult=mysql_query($meaquery) or die ("Couldn't get answers, Type \"E\"<br />$meaquery<br />".mysql_error());
echo "<table>\n";
Expand Down

0 comments on commit 0e8c9b8

Please sign in to comment.