html submit prevent default code example Example: prevent button form submit <button type="button">Button</button>