How to create custom JQuery function and how to use it?
By “custom function” I am assuming you mean “plugin”. If that’s the case, there is a good tutorial on the jQuery site. The basic idea is this: (function($) { $.fn.myPlugin = function() { return this.each(function() { //Do stuff }); }; }(jQuery)); Basically, the code above does a few things. Firstly, it captures the value of … Read more