diff --git a/app.js b/app.js index c109dd9..74790ac 100644 --- a/app.js +++ b/app.js @@ -95,6 +95,22 @@ function require(FN) { return cache[FN]; } +function include(FN) { + var FSO = CreateObject("Scripting.FileSystemObject"); + var T = null; + try { + var TS = FSO.OpenTextFile(FN, 1); + if (TS.AtEndOfStream) return ""; + T = TS.ReadAll(); + TS.Close(); + TS = null; + eval(T); + } catch (e) { + console.error("LOAD ERROR! " + e.number + ", " + e.description + ", FN=" + FN, 1); + return; + } +} + ///////////////////////////////////////////////////////////////////////////////// // Load script, and call app.main() ///////////////////////////////////////////////////////////////////////////////// diff --git a/uriloader.js b/uriloader.js index 9758eb8..d67cd0f 100644 --- a/uriloader.js +++ b/uriloader.js @@ -1,4 +1,6 @@ - +/* + * uriloader.js + */ return { main: function(args) {