ablog

不器用で落着きのない技術者のメモ

WWW::Mechanize をインストールした

環境

$ uname -a
CYGWIN_NT-5.1 ... 1.5.25(0.156/4/2) 2008-06-12 19:34 i686 Cygwin

インストール手順

$ perl -MCPAN -e shell
CPAN> install WWW::Mechanize
Is it OK to try to connect to the Internet? [yes] 

使ってみる

$ perl -MWWW::Mechanize -e '$mech=new WWW::Mechanize(autocheck=>1);$mech->get("http://www.google.com/");$mech->submit_form(fields => {q=>"Englsh"});print $mech->content'

<!doctype html><head><title>Englsh - Google ...