Archive

Posts Tagged ‘submit’

Send HTML form upon confirmation [HTML]

November 29, 2010 Leave a comment

Problem

Before sending a form, you want a confirmation from the user. If his/her reponse is positive, the form will be sent.

Solution

<form action="process.html" method="POST">
    <input type="button" onclick="if (confirm('Are you sure you want to submit this form?')) submit();" value="Submit">
</form>

This tip was taken from here.

Categories: html Tags: , ,