<input type="button" value="OK" onclick="submit(); return false;">
You will need the <form> tag before this if the code is not iside a form.