[ale] elinks with Spidermonkey RHEL5

Lightner, Jeff JLightner at water.com
Mon May 9 15:27:05 EDT 2011


I found Spidermonkey in the EPEL (Fedora sponsored) repository:

js-1.70-8.el5.i386.rpm

js-1.70-8.el5.x86_64.rpm

js-devel-1.70-8.el5.i386.rpm

js-devel-1.70-8.el5.x86_64.rpm

 

I was able to download and install using rpm then compile elinks from
source to find the above.   Running "elinks -version" after that shows
the ECMAScript support is compiled in to the new elinks binary.    Also
setting various ecmas* flags in the elinks.conf does have effect so
clearly it is using them.   (As opposed to another system where I use
the original RHEL5 provided elinks RPM - it complains about  the ecmas*
stuff being invalid options.)

 

It appears that by default it has this enabled but just for good measure
I added:

set ecmascript.enable = 1.

 

Despite that when I pull up the page I see:

"This product requires use of a browser that supports JavaScript"

 

As a test I set the above to 0 on the off chance it was backwards and
saw the same thing.

 

I then set the following:

set ecmascript.error_reporting = 1

 

On pulling up the page I now see a popup box:

 

"            JavaScript Error:

A script embedded in the current document raised the 

    following exception:

 

TypeError:  Window.Focus is not a function 

 

               OK"

 

That seems to suggest that despite the earlier message about needing a
browser that supports JavaScript that it is in fact executing at least
one JS but that it is getting an error.   Can anyone confirm that?

 

Does anyone have any idea what I'd need to do to deal with the
Window.Focus message?

 

Essentially the site is a login page and even though I am able to input
username and password after opening in browser when I tell it to POST it
simply returns to the same login/password page.

 

Alternatively does anyone know a way I can verify a site that is running
JavaScript is actually responding properly from command line rather than
via a browser?    

 

The SpiderMonkey stuff from Mozilla when compiled into elinks is
supposed to do that but given my results I'm not sure if it is or not.


 

Most of the documentation I can find on JavaScript stuff appears to be
aimed at developers testing their own JS from command line rather than
accessing a web page with JavaScript.   Please don't just point me at
sites found in a Google search unless you have used what you are
pointing me at and can help me with examples because my eyes are
bleeding from looking at what Google has shown me so far.

 

 

   

 

________________________________

From: ale-bounces at ale.org [mailto:ale-bounces at ale.org] On Behalf Of
Lightner, Jeff
Sent: Friday, May 06, 2011 1:57 PM
To: Atlanta Linux Enthusiasts
Subject: [ale] elinks with Spidermonkey RHEL5

 

Anyone running elinks with Spidermonkey on RHEL5 for
Javascript/ECMAScript access?   If so can you let me know what you did
to get it working?

 

________________________________________________________________________
__________________

Jeff Lightner | UNIX/Linux Administrator | DS Waters of America, Inc |
5660 New Northside Drive, Ste 250 | Atlanta, GA 30328 
*: (Direct Dial) 678-486-3516 |*: (Cell) 678-772-0018 |
*:jlightner at water.com

 

 

Proud partner. Susan G. Komen for the Cure. 

 

Please consider our environment before printing this e-mail or
attachments. 

----------------------------------
CONFIDENTIALITY NOTICE: This e-mail may contain privileged or
confidential information and is for the sole use of the intended
recipient(s). If you are not the intended recipient, any disclosure,
copying, distribution, or use of the contents of this information is
prohibited and may be unlawful. If you have received this electronic
transmission in error, please reply immediately to the sender that you
have received the message in error, and delete it. Thank you.
----------------------------------

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.ale.org/pipermail/ale/attachments/20110509/c96e6662/attachment.html 


More information about the Ale mailing list