Your right, there is no way of doing it, because you can't specify another [already open] window as the target in the form tag.
What I did was this:
- Submitted the form's results to PHP_SELF.
Then used this code at the top of my form:
if (isset($_POST['adjust'])) {
$adj_q = "UPDATE my_table SET ";
if ($_POST['field1'] != NULL) $adj_q .= "field1='$_POST[field1]', ";
if ($_POST['field2'] != NULL) $adj_q .= "field2='$_POST[field2]', ";
if ($_POST['field3'] != NULL) $adj_q .= "field3='$_POST[field3]', ";
$adj_q = substr($adj_q, 0, -2);
$adj_q .= " WHERE ID='$_POST[ID]' AND sale_date='$_POST[date]'";
mysql_query($adj_q) or showerror();
print "<script>javascript: opener.location.href('settlement.php?create=true&ID=$_POST[ID]&date=$_POST[date]'); self.close()</script>";
}
The opener window get the variables from a $_GET, checks to see if adjustment results are in the database, is refreshed to show the results, and the submitting form gets closed. All transparent to the user.
Thanks for all the ideas!