Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^5: Correct link to put in my WWW:Mechanize

by LanX (Sage)
on Mar 12, 2022 at 19:03 UTC ( #11142040=note: print w/replies, xml ) Need Help??


in reply to Re^4: Correct link to put in my WWW:Mechanize
in thread Correct link to put in my WWW:Mechanize

> Sorry Rolf, I am a bit confused. In my script, I write:
'my $url = 'http://www.csbio.sjtu.edu.cn/bioinf/MemBrain/';'

That's not the code you showed us.

> and, in the source of the page I see:
<form name="myform" action="/cgi-bin/MEMBRAIN.cgi" method="post" onSubmit="javascript: return checkform();">

you are confusing two things:

  1. the static page you open in your browser to see the form
  2. the CGI you can submit your form parameters to.
Which one do you want to mechanize? I can't tell.

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

Replies are listed 'Best First'.
Re^6: Correct link to put in my WWW:Mechanize
by Anonymous Monk on Mar 12, 2022 at 19:09 UTC
    I guess this is where I am confused, as to what do I need to specify in the URL so I can force the page to run using my data. I thought it was enough to put:
    my $url = 'http://www.csbio.sjtu.edu.cn/bioinf/MemBrain/'; my $mech = WWW::Mechanize->new (timeout=>1000); $mech->post($url); #$mech->get($url);

    but it fails to run with the error: Error POSTing http://www.csbio.sjtu.edu.cn/cgi-bin/MEMBRAIN.cgi: Internal Server Error or Error GETing http://www.csbio.sjtu.edu.cn/cgi-bin/MEMBRAIN.cgi: Internal Server Error
    I even tried: my $url=http://www.csbio.sjtu.edu.cn/cgi-bin/MEMBRAIN.cgi, still error...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11142040]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2023-02-07 18:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I prefer not to run the latest version of Perl because:







    Results (40 votes). Check out past polls.

    Notices?