Index: trunk/ippMonitor/def/detNormalizedExp.d
===================================================================
--- trunk/ippMonitor/def/detNormalizedExp.d	(revision 13605)
+++ trunk/ippMonitor/def/detNormalizedExp.d	(revision 13692)
@@ -6,5 +6,5 @@
 # the following WHERE clauses are added to all queries joined by AND
 WHERE detNormalizedExp.det_id    = detRun.det_id
-WHERE detNormalizedExp.iteration = detRun.iteration
+# WHERE detNormalizedExp.iteration = detRun.iteration
 
 # define image names to be used below
Index: trunk/ippMonitor/def/detProcessedImfile.d
===================================================================
--- trunk/ippMonitor/def/detProcessedImfile.d	(revision 13605)
+++ trunk/ippMonitor/def/detProcessedImfile.d	(revision 13692)
@@ -16,2 +16,3 @@
 
 TAIL PHP insert_image ('PPIMAGE.JPEG1');
+TAIL PHP insert_log ('LOG.EXP');
Index: trunk/ippMonitor/def/detResidExp.d
===================================================================
--- trunk/ippMonitor/def/detResidExp.d	(revision 13605)
+++ trunk/ippMonitor/def/detResidExp.d	(revision 13692)
@@ -20,5 +20,5 @@
 ARGS  ARG2 basename=$detResidExp.path_base
 
-OP    OP1  $detResidExp.bg / $detResidExp.bg_stdev
+OP    OP1  $detResidExp.bg / $detResidExp.bin_stdev
 
 #     field                   size    name       show         link to              linkargs
@@ -31,4 +31,5 @@
 FIELD detResidExp.bg_mean_stdev, 8,   [stdev]
 FIELD detResidExp.bg_stdev,      8,   stdev,     value
+FIELD detResidExp.bin_stdev,     8,   bin stdev, value
 FIELD *,                         8,   S/N,       op=OP1
 FIELD rawExp.dateobs,            8,   obs date,  value
Index: trunk/ippMonitor/def/detResidImfile.d
===================================================================
--- trunk/ippMonitor/def/detResidImfile.d	(revision 13605)
+++ trunk/ippMonitor/def/detResidImfile.d	(revision 13692)
@@ -17,3 +17,3 @@
 
 TAIL PHP insert_image ('PPIMAGE.JPEG1');
-TAIL PHP insert_image ('PPIMAGE.JPEG2');
+TAIL PHP insert_log ('LOG.EXP');
Index: trunk/ippMonitor/raw/ipp.php
===================================================================
--- trunk/ippMonitor/raw/ipp.php	(revision 13605)
+++ trunk/ippMonitor/raw/ipp.php	(revision 13692)
@@ -451,4 +451,63 @@
 // expect image supplied with key=name
 // this function should define matching hidden inputs in the form
+function insert_log ($filerule) {
+
+  if ($_SERVER[REQUEST_METHOD] == 'GET') { 
+    $basename = $_GET['basename']; 
+    $class_id = $_GET['class']; 
+    $camera   = $_GET['camera']; 
+  } else {
+    $basename = $_POST['basename']; 
+    $class_id = $_POST['class']; 
+    $camera   = $_POST['camera']; 
+  }
+
+  if (! $class_id) { $class_id = "NONE"; }
+
+  if ($basename && $camera && $filerule) {
+
+    // do I need to do this to the output result as well?
+    $basename = escapeshellarg($basename);
+    $basename = str_replace ('..','',$basename);
+
+    # XXX !!!
+    $PERLLIB = "/home/kiawe/eugene/psconfig/dev.linux/lib";
+    $BINDIR = "/home/kiawe/eugene/psconfig/dev.linux/bin";
+    $SITE = "/home/kiawe/eugene/.ipprc";
+    putenv("PERL5LIB=$PERLLIB:");
+    $PATH = getenv("PATH");
+    putenv("PATH=$BINDIR:$PATH");
+
+    // echo "<br><b>ipp_filename.pl --site=$SITE --basename $basename --filerule $filerule --camera $camera --class_id $class_id</b><br>\n";
+    exec ("ipp_filename.pl --site=$SITE --basename $basename --filerule $filerule --camera $camera --class_id $class_id", $output, $status);
+
+    if (0) {
+      echo "basename: $basename<br>";
+      for ($i = 0; $i < count($output); $i++) {
+	echo "output $i: $output[$i]<br>";
+      }
+      echo "output:   $output[0]<br>";
+      echo "status:   $status<br>";
+      echo "filename: $filename<br>";
+      exit ();
+    }
+
+    $filename = $output[0];
+    if ($status) {
+      echo "log file not found<br>\n";
+      return;
+    }
+
+    echo "<pre>\n";
+    $file = fopen ($filename, "r");
+    if ($file && !$debug) {
+      fpassthru ($file);
+    }
+    echo "</pre>\n";
+  }
+}
+
+// expect image supplied with key=name
+// this function should define matching hidden inputs in the form
 function insert_backref ($page, $key, $link) {
 
