Wednesday, 11 September 2013

Make your own JQuery plugin


JQuery plugin :   

        (function ($) {
            $.fn.HelloWorld = function (e) {
                alert(e);
            }
        }(jQuery)); 

Use Plugin :
 
        $(document).ready(function () {
            $("#temp").HelloWorld("Test Plugin");
        })

No comments:

Post a comment