cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: curl and javascript

From: Ralph Mitchell <rmitchell_at_eds.com>
Date: Tue, 08 Jul 2003 06:00:33 -0500

The bad news is, curl doesn't interpret javascript.

The good news is that if you read the pages and can work out what the
javascript actually does, there's a fair chance of actually working
around it.

So, start by dragging the first page off the server and take a peek. I
generally strip out all the "fluff" - table tags, font tags, etc - then
any javascript that's a "no-op", such as image swapping scripts (I'm not
getting the images anyway, so who cares?)...

If you're left with javascript such as "onSubmit" functions, be very
careful about discarding those. In several cases, I've had javascript
onSubmit functions that assembled a new url from form elements, then did
something like "top.location=newurl" to automagically jump to the new page.

Once you reduce the page to its simplest form, try posting it back and
see what you get in reply. Lather, rinse, repeat...

Ralph Mitchell

Michael Steinhoff wrote:

>Hi all,
>
>to begin with, i'm a newbie and maybe the answer is obvoius, but i'm too blind to see...
>
>I need to retrieve logfiles via https from a webserver. I want schedule this with a batch file and thought of curl as an way to do it.
>
>The problem is, that the webserver requires javascript.
>
>how can i accomplish this with curl or is no option for me?
>
>any hint is greatly appreciated
>
>thanks
>
>michael
>______________________________________________________________________________
>Werden Sie kreativ! Jetzt HTML-Mails nicht nur schreiben - nein -
>GESTALTEN, bei WEB.DE FreeMail! http://freemail.web.de/features/?mc=021141
>
>
>
>-------------------------------------------------------
>This SF.Net email sponsored by: Free pre-built ASP.NET sites including
>Data Reports, E-commerce, Portals, and Forums are available now.
>Download today and enter to win an XBOX or Visual Studio .NET.
>http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01
>
>

-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01
Received on 2003-07-08