Call Jquery function

前端 未结 4 1082
一整个雨季
一整个雨季 2021-02-04 06:53

I have a Jquery function like the following

function myFunction(){  
            $.messager.show({  
                title:\'My Title\',  
                msg:\'         


        
4条回答
  •  醉梦人生
    2021-02-04 07:17

    Just add click event by jquery in $(document).ready() like :

    $(document).ready(function(){
    
                      $('#YourControlID').click(function(){
                         if(Check your condtion)
                         {
                                 $.messager.show({  
                                    title:'My Title',  
                                    msg:'The message content',  
                                    showType:'fade',  
                                    style:{  
                                        right:'',  
                                        bottom:''  
                                    }  
                                });  
                         }
                     });
                });
    

提交回复
热议问题