Sep 19th, 2010, 9:18 AM
Hi Hannes,
Yeah, this is one of those loose ends I've never managed to tidy up. There's nothing built-in for this, but you could definitely add something yourself.
I'd probably approach it like this: do a test on the form page to see if $_FILES wasn't empty, then after the submission has been updated, check to see if the file actually made it into the DB record. If it didn't, DON'T redirect to the next page and just display an error in the page.
Again (as per my response to your previous post) this is kind of a deficiency in the API. I'll have to give this some more thought. Be very nice if it handled this scenario more gracefully.
- Ben
Yeah, this is one of those loose ends I've never managed to tidy up. There's nothing built-in for this, but you could definitely add something yourself.
I'd probably approach it like this: do a test on the form page to see if $_FILES wasn't empty, then after the submission has been updated, check to see if the file actually made it into the DB record. If it didn't, DON'T redirect to the next page and just display an error in the page.
Again (as per my response to your previous post) this is kind of a deficiency in the API. I'll have to give this some more thought. Be very nice if it handled this scenario more gracefully.
- Ben