Answers for "how to call js function in jquery"

0

how to create jquery function

(function( $ ){
   $.fn.myfunction = function() {
      alert('hello world');
      return this;
   }; 
})( jQuery );

$('#my_div').myfunction();
Posted by: Guest on March-20-2021
0

how to call function in jquery

$(document).ready(function() {
  $('#btnSun').click(myFunction);
});

function myFunction() {
  alert('hi');
}
Posted by: Guest on March-19-2021

Code answers related to "how to call js function in jquery"

Code answers related to "Javascript"

Browse Popular Code Answers by Language