Preventing Double Form Submission

 
form action="#" method="post" class="myform"
  ----
  ----
 input type="submit" name="submit" value="Submit" class="msg_button" 
 /form


$('.myform').submit(function(e)
                        {
                                // hide the submit button 
                                $('.msg_button').hide();
                                // submit the form
                                return true;
                        });