/*! jQuery printElement - v2.0.1 - 2014-08-22 * https://github.com/erikzaadi/jQuery.printElement * Copyright (c) 2014 erikzaadi; Licensed MIT, GPL */ !function(a){function b(b,d){var e=f(b,d),i=null,j=null;if("popup"===d.printMode.toLowerCase())i=a.open("about:blank","printElementWindow","width=650,height=440,scrollbars=yes"),j=i.document;else{var k="printElement_"+Math.round(99999*Math.random()).toString(),l=g.createElement("IFRAME");h(l).attr({style:d.iframeElementOptions.styleToAdd,id:k,className:d.iframeElementOptions.classNameToAdd,frameBorder:0,scrolling:"no",src:"about:blank"}),g.body.appendChild(l),j=l.contentWindow||l.contentDocument,j.document&&(j=j.document),l=g.frames?g.frames[k]:g.getElementById(k),i=l.contentWindow||l}focus(),j.open(),j.write(e),j.close(),c(i)}function c(a){a&&a.printPage?a.printPage():setTimeout(function(){c(a)},50)}function d(a){var b=h(a);h(":checked",b).each(function(){this.setAttribute("checked","checked")}),h("input[type='text'],input[type='number']",b).each(function(){this.setAttribute("value",h(this).val())}),h("select",b).each(function(){var a=h(this);h("option",a).each(function(){a.val()===h(this).val()&&this.setAttribute("selected","selected")})}),h("textarea",b).each(function(){var a=h(this).attr("value");this.firstChild?this.firstChild.textContent=a:this.innerHTML=a});var c=h("
").append(b.clone()).html();return c}function e(){var b=a.location.port?":"+a.location.port:"";return a.location.protocol+"//"+a.location.hostname+b+a.location.pathname}function f(a,b){var c=h(a),f=d(a),i=[];if(i.push("