View Full Version : Max length of js-files?
07-04-2002, 01:20 PM
I have got a weird problem... It seems like my js-file, which is included in a popup, is cut off before it has been fully loaded. What could be the problem???
The error message I'm receiving when loading the popup-window is "Row x Char y 'funct is undefined' - but there is only functIONS in my js-file! :eek:
07-04-2002, 02:45 PM
I guess "funct" is an abbreviation of "function"... Can you offer people a look at your script, and maybe a URL to your page(s)? Without being able to see what you have it's practically impossible to give concrete advise.
07-04-2002, 03:14 PM
Sorry, I will try to describe my problem better...
Please, help! :(
07-04-2002, 03:26 PM
Too much is not usually a problem in programming, but if it returns "funct" I'd say that your browser either ran out of cache or memory, or you put a space in accidentaly, but you might not find the space very obvious, so I (personally) suggest that you do two things:
1) open up your *.js file and do a search for "funct", or "funct ",
and if you find it, try loading again (after saving of course)
2) break up your *.js file and categorize or link seperately.
07-04-2002, 03:28 PM
What are you trying to accomplish with that script?!! I guess it's rather big, and am curious about load and execution times anyway! I really wouldn't know if there's a limit to how big a page can be, but it looks like you found it (the limit, that is).
07-04-2002, 04:21 PM
..hmmm.. I'm curious how big the js file is...
..also, if it does run out of memory or gets to "some other size limit" it should error when that size is reached. Add some code in the begining of the script and see if it errors in a different place other than funct.....
07-08-2002, 12:38 PM
Thank's for the answers!
The problem disappeared when I split the file into separate include-files. It seems that the file was too large - but the question is why this happens only in some occasions? The same large include-file is included in almost all of my html-pages, but the problem only appeares in a few occasions... Perhaps it has something to do with different loading times...?
Well, the problem is solved for now!
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.