function queryUpdateTableRelation($param) { queryDeleteTableRelation($param); // Delete the previous relationship queryDefineTableRelation($param); // Define the "updated" relationship (really a new one since we deleted the old) }
$stmt->fetch(); $Parent = $Parent_Table . '.' . $Parent_Field; $Child = $Child_Table . '.' . $Child_Field; $stmt->close(); } else { die("Umm... " . $stmt->error); } $mysqli->close(); } elseif (xsrf_guard()) { init_var($_POST['btnCancel']); init_var($_POST['btnSubmit']); if ($_POST['btnCancel']) { header('location: ListView_TableRelations.php'); exit; } elseif ($_POST['btnSubmit']) { queryDeleteTableRelation($_POST); header("location: ../success.php?success_tag=DeleteTableRelations"); exit; } } drawHeader(); drawPageTitle('Delete Relationship', 'Are you sure you wish to delete this relationship?'); echo '<input type="hidden" name="Relation_ID" value="' . $Relation_ID . '">'; ?> <div class="container_mid_huge"> <fieldset class="top"> Delete Relationship </fieldset> <fieldset class="middle"> <table class="input_form">