To trigger an event of an element, trigger()
method can be used.
<script>
$("#divTrigger").click(function () {
$("form").trigger('submit');
});
</script>
In the above code when “divTrigger” is clicked then form “submit” event triggers (the behavior will be same as if the form is being submitted).
Views: 5023 | Post Order: 87