대화 형 메뉴가있는 http://revigo.irb.hr/ 웹 사이트에서 정보를 다운로드하고 싶습니다. 나는 마지막 코드는 다음과 같다perl을 사용하여 양식 채우기 WWW :: Mechanize :: Formfiller
perl -MWWW::Mechanize::Shell -e shell
get http://revigo.irb.hr/
fillout
...
submit
script
사용하여 양식 필드를 가져 오는 한 후 다음과 같은 펄 코드를 시도하고있다 :
나는 다음과 같은 오류 메시지가 납니다 그러나 use strict;
use WWW::Mechanize;
use WWW::Mechanize::FormFiller;
use URI::URL;
my @go_terms=qw/GO:0006612 GO:0045862 GO:0048545 GO:0007568 GO:0046326 GO:0051901 GO:0010524 GO:0006044 GO:0032024/;
my $go_string=join("\n",@go_terms);
my $agent = WWW::Mechanize->new(autocheck => 1);
my $formfiller = WWW::Mechanize::FormFiller->new();
$agent->env_proxy();
$agent->get('http://revigo.irb.hr/');
$agent->form_number(1) if $agent->forms and scalar @{$agent->forms};
$formfiller->add_filler('goList' => Fixed => $go_string);
$formfiller->add_filler('cutoff' => Fixed => '0.4');
$formfiller->add_filler('isPValue' => Fixed => 'yes');
$formfiller->add_filler('whatIsBetter' => Fixed => 'higher');
$formfiller->add_filler('goSizes' => Fixed => '0');
$formfiller->add_filler('measure' => Fixed => 'SIMREL');
$formfiller->fill_form($agent->current_form);
my $request = $agent->click("startRevigo");
print $request->as_string;
"오류가 http://revigo.irb.hr/revigo.jsp을 게시 : 내부 서버 오류가 revigo.mechanize.pm 라인 21 " 아무도 내가 문제를 해결하는 데 도움이 될 수 있습니까? 미리 감사드립니다.
라인 21은 어느 라인입니까? – simbabque
원래 21 번째 줄에는 $ request = $ agent-> click ("startRevigo"); 감사합니다. 문제가 해결되었습니다. – WoA