twilightnights Posted January 29, 2007 Share Posted January 29, 2007 Is there a very easy way to prevent someone from submitting the same information more than 1 time to a database? Link to comment https://forums.phpfreaks.com/topic/36146-easiest-way-to-prevent-reposts/ Share on other sites More sharing options...
btherl Posted January 29, 2007 Share Posted January 29, 2007 You can check if the information is already in the database before adding it.If that doesn't answer your question, please provide some more detail so we can help you better :) Link to comment https://forums.phpfreaks.com/topic/36146-easiest-way-to-prevent-reposts/#findComment-171665 Share on other sites More sharing options...
chronister Posted January 29, 2007 Share Posted January 29, 2007 I agree with btherl,Gather up your data that has been submitted, and run a query to see if the data exists, if not then another query to add it, else print an error message to user stating that the data already exists. Link to comment https://forums.phpfreaks.com/topic/36146-easiest-way-to-prevent-reposts/#findComment-171678 Share on other sites More sharing options...
ted_chou12 Posted January 29, 2007 Share Posted January 29, 2007 if what you mean is clicking refresh, then you can redirect them using header("location: ..."); to guide them to another page so even if they do click refresh, the form wont submit again.Ted Link to comment https://forums.phpfreaks.com/topic/36146-easiest-way-to-prevent-reposts/#findComment-171776 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.