Hey
Do you mean that when you refresh, the data in the form is re-submitted by the browser?
If so there are limited solutions. Easiest is to send the form to a new page (rather than to itself). Assuming you have reasons for sending it to itself then you have some options:
1. Use the database to keep track of things. Ensure that data is only submitted once by storing an ID of some sort which you can check each time - only let one submit per ID. You can also compare the data submitted with the data already there and if they're the same, reject the submission.
2. Make fields 'Unique' - add a unique index to your DB columns - bit blunt - DB will return an error if they're the same.
3. (my favourite). You force a reload using the
- header('Location: http://www.thisiste.com/thispage.php')
function. This uses HTTP to redirect the page (to itself to reload). If you want to tell the user about errors, you would need to use cookies or sessions in this case.
If, on the other hand your problem was something else then just ignore me ;)!
Henry