[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Bug-wget] pushing button(s)

From: Tony Lewis
Subject: RE: [Bug-wget] pushing button(s)
Date: Sat, 17 Apr 2010 09:00:36 -0700

> Voytek Eymont wrote:

>>> <input class="albttn_red" name="Accept" onclick="javascript: return
>>> Al_Click_Button(active_list, '21583679','page_generator', 'default');"
>>> Value="Accept" title="Accept" type="button">&nbsp;
>       function Al_Click_Button(frm, al_disp_id, module, template) {
>               frm._module.value=module;
>               frm._template.value=template;
>               frm._al_action_click.value = 1;
>               frm._al_disp_id.value = al_disp_id;
>               frm.submit();
>               return true;

Within the HTML you will find a form that is referenced as "active_list".
That could be the ID of the form or there could be a JavaScript variable
named active_list set to point to that object.

When you click on the Accept button, the JavaScript sets fields within that
form to particular values and then submits the form. In this particular
example, the values are set as follows:


To replicate the behavior in wget, you need to locate the action of the form
object. For example, you might find something like this in the HTML:

<form id=active_list action="/cgi-bin/accept.cgi" method=GET>

In that case, you would invoke wget with:


(The arguments went into the URL because the method was GET.)

If you found something like this:

<form id=active_list action="/cgi-bin/accept.cgi" method=POST>

You would invoke wget with:

wget "http://the.server.name/cgi-bin/accept.cgi";

As Micah said, you need to understand the JavaScript and the HTML to be able
to replicate what the browser does. I hope this helps you along the way. I
strongly suspect that you will need to write a script that retrieves the
initial page, parses the behavior of the ACCEPT button, and the invokes wget

Good luck.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]