Submit an HTML form without having a submit button?

前端 未结 11 1473
攒了一身酷
攒了一身酷 2021-01-01 18:57

Can I submit a html

with
instead of ?

Like this:

         


        
11条回答
  •  心在旅途
    2021-01-01 19:39

    How about this:

     $(document).ready(function() {
         $('#submitDiv').click(function() {
            $('#myForm').submit();
         });
    
    }); 
    
    
    
    
    
    
    Submit the form by clicking this

提交回复
热议问题