Here is my javascript file that I'm loading from a standalone Java
program:
print("starting js");
try{
Packages.org.mozilla.javascript.Context.getCurrentContext().setOptimization Level(-1);
load('C:\\projects\\xyz\\TestProject\\js\\env.rhino.1.2.js');
Envjs.scriptTypes['text/javascript'] = true;
Envjs.scriptTypes['text/envjs'] = true;
Envjs.scriptTypes[''] = true;
window.location = 'http://localhost:8080/';
}catch(e){
print(e);
}
print("ending js");
I can see on my app server console that the various parts of the
application are being called including ajax calls that build dynamic
content on the page. However, the program never exits. I never see
the "ending js" line. It seems to hang. I would like to be able to
query for some information on the "screen", but it never gets any
further than the window.location line. Any hints or tips?
I've tried both Rhino 1.7R2 and R3. I'm on Java 1.6.
Thanks.