in jQuery

Simple jQuery Plugin Example

And in summation

In this article I demonstrated how to build a jQuery plugin. Even though the plugin I built was very trivial and quite useless in itself, it does demonstrate the essentials of how all jQuery plugins are built. You can use the example in this article to build much more complex plugins.