confirm before form submit php code example Example: confirm before submit form php onclick="return confirm('Are you sure you want to submit this form?')"