MCPcopy Create free account
hub / github.com/TruthHun/BookStack / setDocType

Function setDocType

static/js/printThis.js:133–141  ·  view source on GitHub ↗
($iframe, doctype)

Source from the content-addressed store, hash-verified

131
132 // Add doctype to fix the style difference between printing and render
133 function setDocType($iframe, doctype){
134 var win, doc;
135 win = $iframe.get(0);
136 win = win.contentWindow || win.contentDocument || win;
137 doc = win.document || win.contentDocument || win;
138 doc.open();
139 doc.write(doctype);
140 doc.close();
141 }
142
143 if (opt.doctypeString){
144 setDocType($iframe, opt.doctypeString);

Callers 1

printThis.jsFile · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected