MCPcopy Create free account
hub / github.com/JsAaron/jQuery / disableScript

Function disableScript

2.1.1/test/jquery-2.1.1.js:4929–4932  ·  view source on GitHub ↗
( elem )

Source from the content-addressed store, hash-verified

4927
4928// Replace/restore the type attribute of script elements for safe DOM manipulation
4929function disableScript( elem ) {
4930 elem.type = (elem.getAttribute("type") !== null) + "/" + elem.type;
4931 return elem;
4932}
4933function restoreScript( elem ) {
4934 var match = rscriptTypeMasked.exec( elem.type );
4935

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected