Re: Executing Javascript from HTML pages in perl
by jryan (Vicar) on Nov 06, 2002 at 22:25 UTC
|
Theres a Javascript module on the CPAN that can execute JavaScript code; perhaps you can use that somehow? | [reply] |
(Javascript::SpiderMonkey) Re: Executing Javascript from HTML pages in perl
by PodMaster (Abbot) on Nov 07, 2002 at 06:23 UTC
|
jryan is right on the money.
I have a win32 ppm package of Javascript here
Documentation is kind of scarce for Javascript, but you're in luck,
there exists Javascript::SpiderMonkey by the same author, which is being actively maintained (see documentation).
I'll see about putting up a ppm of Javascript::SpiderMonkey later.
____________________________________________________ ** The Third rule of perl club is a statement of fact: pod is sexy. | [reply] |
|
|
I am running my code on linux so the Javascript::SpiderMonkey won't help. I beleve Javascript.pm has very limited funcionalitity.
| [reply] |
|
|
| [reply] |
Re: (nrd) Executing Javascript from HTML pages in perl
by newrisedesigns (Curate) on Nov 06, 2002 at 20:48 UTC
|
but what do I do when it comes to javascripting?
Ignore it. Odds are it won't affect how you work.
Do you have an example or something in particular in mind?
John J Reiser
newrisedesigns.com
| [reply] |
|
|
An example of a url would be https://chaseonline.chase.com/chaseonline/logon/sso_logon.jsp. If you try to do a get with LWP, it says that your browswer does not support javascript. Also, if you look a the source code, the post action is to a javascript. Similarly if you look at yahoo, the login requires it post to a javascript which in turn does a post.
| [reply] |
Re: Executing Javascript from HTML pages in perl
by Mr. Muskrat (Canon) on Nov 06, 2002 at 20:59 UTC
|
That all depends on why the javascript was included in the HTML. So take a good, long look at that javascript and ask yourself: Do I really need this? If your answer is yes, then provide the same functionality in your Perl script.
| [reply] |
|
|
And what if the javascript happens to be DOM manipulation (i.e. the stylesheet maninipulation I use in Text::ParagraphDiff output), or a form checker? Not everything javascript can do can be mimicked with perl.
| [reply] |
|
|
| [reply] |
|
|
|
|
|
|
|
| [reply] |
|
|
|
|
Re: Executing Javascript from HTML pages in perl
by Ananda (Pilgrim) on Nov 07, 2002 at 05:02 UTC
|
What if the scripting is acheived through externas js files and also how about the External .Css files.
Anandatirtha | [reply] |