when the user clicks on a form button to get to next page then an email will be sent to the administrator. but then the user might have clicked twice thus causing multiple emails to send to the administrator . is there any way to ensure that the user only clicks once?
i thought of this: whenever the user click once, the button would be disabled to prevent the user from clicking it twice. can use javascript is it? is there a way to do it using php because my application is in php codes.
If you are using regular HTML form, once the submit button clicked it should load the web page set in the action attribute of the form tag. I very surprised how you are getting the problem.
If you want to disable it though once it is been clicked, you will have to do it client side with JavaScript. PHP is server side, so you will not be able to do it that way.
However, keep in mind that users might disable JavaScript on their web browser, in that case the button will not get disabled.