Jump to content

Preventing resubmission?


Michdd

Recommended Posts

You could put in a line at the top that checks to see if the file exists on the server. Then if it does exist don't run the rest of the script.

 

But that might prevent over writing of the file which you might not like.

 

Also add in lines after the upload part of the script that clean out the variables holding the upload info.

 

And then a check at the beginning perhaps.

Link to comment
Share on other sites

You could put in a line at the top that checks to see if the file exists on the server. Then if it does exist don't run the rest of the script.

 

But that might prevent over writing of the file which you might not like.

 

Also add in lines after the upload part of the script that clean out the variables holding the upload info.

 

And then a check at the beginning perhaps.

 

I already got the check, but how do I clear the variables?

Link to comment
Share on other sites

If you use sessions then the variables will still hold their values.

 

 

Sessions will hold there value till the page is closed. But the variable will not hold its value. But a variable can be declared to hold the sessions value. So the variable isn't actually holding the data but the session itself. So the variable will be gone when gone to a different page but the session will still exist. Till browser is closed.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.