<?php      //      order/update

if ($FORM{'mode'} eq "update" and $FORM{'submit'} eq "Update") {
   # handle shipped, remove, update QTY, return, reship information
   $orderid = $FORM{'orderid'};

   $linecounter = 0;
   for (1..$FORM{'linecounter'}) {
      $linecounter ++;
      $lineid = $FORM{"LINE$linecounter"};

      if ($FORM{"ACT$lineid"} eq "Update QTY") {
=cut
	$l="update ocart set quant=$FORM{'QTY$lineid'} where lineid=$lineid";
	$stl=$dbh->prepare($l);
	$stl->execute;
        $stl->finish;

        $l="insert into levents(dtable, dvalue, cdate) values ('ocart', '$lineid\tUpdated', '$now');
	$stl=$dbh->prepare;
        $stl->execute;  
        $stl->finish;
=cut
      } elsif ($FORM{"ACT$lineid"} eq "Reship") {

      } elsif ($FORM{"ACT$lineid"} eq "Return") {



      } elsif ($FORM{"ACT$lineid"} eq "Remove") {

      } elsif ($FORM{"ACT$lineid"} eq "Shipped") {


      } 

   }
}
