(function($){
$.fn.getHTML = function(){
var $content = $(this);
$content.find(":button,:submit,input[type=\"file\"],input[type=\"hidden\"],input[type=\"image\"],input[type=\"password\"],input[type=\"reset\"]").remove();
$content.find(":checkbox:checked").attr("checked","checked");
$content.find(":radio:selected").attr("selected","selected");
$content.find(":radio:checked").attr("checked","checked");
$content.find(":checkbox,:radio").attr("disabled","disabled");
$content.find("input[type=\"text\"],textarea,select,input:not([type])").each(function(){
$(this).replaceWith($(this).val().replace(/\n/g,"
\n"));
});
return $content.html();
}
}(jQuery));