What is the best practice for including jQuery ext functions?
<p>Currently I have a file that I named JQuery.ext.js which I am including in all of my pages. Inside this file I have numerous functions that do things like the following,</p>

<pre><code>(function($) {


    /**
     * Checks to see if a container is empty. Returns true if it is empty
     * @return bool
     */
    $.fn.isEmptyContainer = function() {
        //If there are no children inside the element then it is empty
        return ($(this).children().length &lt;= 0) ? $(this) : false;
    };

    /**
     * Strip html tags from elements
     * @return jQuery
     */
    $.fn.stripHTML = function() {
        var regexp = /&lt;("[^"]*"|'[^']*'|[^'"&gt;])*&gt;/gi;

        //Loop through all elements that were passed in
        this.each(function() {
            $(this).html($(this).html().replace(regexp, ""));
        });
        return $(this);
    };

    /**
     * This function will check the length of a textarea and not allow the user to go beyond this length.
     * You should use the onkeypress event to trigger this function
     *
     * @param event event This value should always be event when passing it into this function
     * @param maxlength int The maximum amount of character that the user is allowed to type in a textarea
     */
    $.fn.enforceMaxLength = function(event, maxlength) {
        //Only allow the client code to use the onkeypress event
        if(event.type == 'keypress') {
            //If the client code does not pass in a maxlength then set a default value of 255
            var charMax = (!maxlength || typeof(maxlength) != "number") ? 255 : maxlength;

            //If the user is using the backspace character then allow it always
            if(event.which == 8) { return true; }
            //Else enforce the length
            else { return ($(this).val().length &lt;= charMax); }
        }

        //Will only get here if the event type is not keypress
        return false;
    };
})(jQuery);
</code></pre>

<p>Is there another way to do this? or is this the way most people do it?</p>

<p>Thanks for any help, Metropolis</p>

<p><strong>EDITED</strong></p>

<p><strong>Added different plugins to the code and removed the validation plugins</strong></p>
