mirror of
https://github.com/Investigamer/cardconjurer.git
synced 2025-07-27 13:21:41 -05:00
better scripts
This commit is contained in:
9
data/scripts/old/loadScript.js
Normal file
9
data/scripts/old/loadScript.js
Normal file
@@ -0,0 +1,9 @@
|
||||
//Allows javascript files to be loaded through javascript code
|
||||
function loadScript(scriptName){
|
||||
var script = document.createElement("script")
|
||||
script.setAttribute("type","text/javascript")
|
||||
script.setAttribute("src", scriptName)
|
||||
if (typeof script != "undefined") {
|
||||
document.getElementsByTagName("head")[0].appendChild(script)
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user