I am using a custom-built javascript file include function (code at bottom
of email)
to include .js files within other .js files, and have created some code
that works fine in IE and NS6, but crashes NS4.7 (the page never finishes
loading).
The root file has the following four lines:
<script language="Javascript" src="main.js"></script>
<script language="Javascript">
Main.include("level1.js")
</script>
The problematic lines in level1.js are as follows:
Main.include("/util/objectUtil.js")
Main.include("/util/arrayUtil.js")
Main.include("/util/stringUtil.js")
Main.include("/select/select.js")
If I comment out all but one of the includes, the code is ok:
it only crashes when I try to include more than one file. Does anyone
have any idea what's causing this?
thanks,
jonah
Code for main.js
------------------
function Main() {}
Main.include = includeFile
Main.basePath = "/tms/js"
function includeFile(name,path) {
var path = path ? path : Main.basePath
fullPath = path + name
document.writeln('<script language="Javascript" src="' + fullPath +
'"><\/script>')
}
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dynapi-help