To deal with the lack of this function in jQuery (read-only version).

jQuery.fn.outer = function() { return jQuery(jQuery('<div></div>').html(this.clone())).html(); }