jQuery Submit() Event Example

This is useful for checking if certain fields are filled in or you want to perform an AJAX request with the form data.

HTML

<form method="get" action="https://www.google.com" target="top">
    <input type="text" name="q" value="">
    <input type="submit" value="Search Google">
</form>

JavaScript

$('form').submit(function() {
    return confirm('Transfer ister misin ');
});