Received: by 10.52.88.174 with SMTP id bh14mr16991765vdb.6.1340207277604; Wed, 20 Jun 2012 08:47:57 -0700 (PDT) X-BeenThere: envjs@googlegroups.com Received: by 10.221.13.130 with SMTP id pm2ls716887vcb.6.gmail; Wed, 20 Jun 2012 08:47:57 -0700 (PDT) Received: by 10.52.94.147 with SMTP id dc19mr1643400vdb.17.1340207277107; Wed, 20 Jun 2012 08:47:57 -0700 (PDT) Date: Wed, 20 Jun 2012 08:47:56 -0700 (PDT) From: Saad To: envjs@googlegroups.com Message-Id: <54cb9bea-0af3-477f-a833-5c6d7c477562@googlegroups.com> Subject: env.js + rhino + FlyingSaucer MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_68_19524385.1340207276812" ------=_Part_68_19524385.1340207276812 Content-Type: multipart/alternative; boundary="----=_Part_69_17558824.1340207276812" ------=_Part_69_17558824.1340207276812 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit I used env.js and rhino to run JavaScript and HTML code. I understand this should give me a DOM which can be used with FlyingSaucer. However I am having trouble connecting FlyingSacucer with env.js and rhino. I am embedding env.js in rhino in a java application: Context cx = ContextFactory.getGlobal().enterContext(); cx.setOptimizationLevel(-1); cx.setLanguageVersion(Context.VERSION_1_5); Global global = Main.getGlobal(); global.init(cx); Main.processSource(cx, currentDir+"/lib/custom-script.js"); custom-script.js loads env.js and the specified html file that needs to be read. Any help is appreciated, thanks! ------=_Part_69_17558824.1340207276812 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit
I used env.js and rhino to run JavaScript and HTML code. I understand this should give me a DOM which can be used with FlyingSaucer. However I am having trouble connecting FlyingSacucer with env.js and rhino.

I am embedding env.js in rhino in a java application:

Context cx = ContextFactory.getGlobal().enterContext();
cx.setOptimizationLevel(-1);
cx.setLanguageVersion(Context.VERSION_1_5);
Global global = Main.getGlobal();
global.init(cx);
Main.processSource(cx, currentDir+"/lib/custom-script.js");
custom-script.js loads env.js and the specified html file that needs to be read.

Any help is appreciated, thanks!
------=_Part_69_17558824.1340207276812-- ------=_Part_68_19524385.1340207276812--