|
I am writing a php script that lets a user choose image files on their hard drive for later upload.
When they select a file I post back to the same page and add the file path and name string to a session array.
Every time they choose a file and the php posts back to the same page, I loop through the array and draw a table that shows the images that have been picked.
Here is where I am confused:
I want a "remove" button next to each image in the table. That button would once again post back to the same page sending a variable in the query string representing the array index of that image. It would remove that index from the array and redraw the table.
I have created a working example but to do that I had to put each "remove" button in it's own form.
******************
I would MUCH rather draw the whole table in the same form. Can I make a form post back to different url depending on which button was clicked?
******************
Thanks for your time,
Stan
|