Confirmation dialog with server message
Posted: Thu Jun 26, 2008 9:42 pm
Hi,
I'm trying to write a delete file confirmation capability - php generates a list of files to delete, the user selects a file, with javascript confirmation on the client, and a message gets sent back to the server to delete the file. I've got the filelist generated and have the javascript confirmation, but I really want the original page displayed, not the php page that's called to actually delete the file.
The snippet I have is:
<form name="form1" method="post" onsubmit="return validate_selection(this);"
action="action.php?link=delete_file"><b>Delete File</b><br>
<select name="delete_file" size="3" id="delete_file">
<option value="file_1">File_1</option>
<option value="file_2">File_2</option>
<option value="file_3">File_3</option>
<option value="file_4">File_4</option>
</select>
<input type="submit" name="Submit" value="Delete">
< other stuff >
where validate_selection() does the confirmation and action.php performs the actual delete. But I don't want the <other stuff> removed from the screen after the exchange with the user....
what am I missing?
thanks in advance...
-Peter
I'm trying to write a delete file confirmation capability - php generates a list of files to delete, the user selects a file, with javascript confirmation on the client, and a message gets sent back to the server to delete the file. I've got the filelist generated and have the javascript confirmation, but I really want the original page displayed, not the php page that's called to actually delete the file.
The snippet I have is:
<form name="form1" method="post" onsubmit="return validate_selection(this);"
action="action.php?link=delete_file"><b>Delete File</b><br>
<select name="delete_file" size="3" id="delete_file">
<option value="file_1">File_1</option>
<option value="file_2">File_2</option>
<option value="file_3">File_3</option>
<option value="file_4">File_4</option>
</select>
<input type="submit" name="Submit" value="Delete">
< other stuff >
where validate_selection() does the confirmation and action.php performs the actual delete. But I don't want the <other stuff> removed from the screen after the exchange with the user....
what am I missing?
thanks in advance...
-Peter