Article View: es.comp.os.linux.programacion
Article #569Re: WWW::Mechanize
From: Gonzalo Pérez de Olaguer Córdoba
Date: Mon, 19 Mar 2007 01:50
Date: Mon, 19 Mar 2007 01:50
32 lines
1990 bytes
1990 bytes
Hola "N.Asenjo" <natxo@natxo.invalid> el 18 Mar 2007 21:34:58 GMT escribiste: > > el formato no me ha quedado bien. mi cĂłdigo en realidad está asĂ: > > #!/usr/bin/perl > > use strict; > use warnings; > use WWW::Mechanize; > > my $url = "http://tux"; > my $links; > my @links; > # create new instance of WWW::Mechanize my $mechanize = > WWW::Mechanize->new(autocheck => 1); > > $mechanize->get( $url ); > my @links = $mechanize->links(); > print @links; Por tu mensaje anterior parece que @links es un array de arrays. Si el man page de WWW::Mechanize no te describe en detalle lo que devuelve $mechanize->links() intenta averiguarlo con: use Data::Dumper; print Dumper (@links); -- Gonzalo PĂ©rez de Olaguer CĂłrdoba <gpoc@iies.es> PGP key 2861C704 --- F206 5671 6789 425D 111C 1302 214F 1934 2861 C704
Technical Details
Message-ID:
<20070319025018.3d86316a@petres.salonet.snet>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!news.antakira.com!cagarruta.escomposlinux.org!hercules.escomposlinux.org!escomposlinux.org!not-for-mailReferences:
<slrnevrbua.h1.natxo@tux.asenjo.nx> <slrnevrc42.1lg.natxo@tux.asenjo.nx>Show Full Headers
Complete Article Headers
X-Google-Thread: f86c8,7ee3d532f70798c3 X-Google-Attributes: gidf86c8,public X-Google-Language: ENGLISH,ASCII Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!news.antakira.com!cagarruta.escomposlinux.org!hercules.escomposlinux.org!escomposlinux.org!not-for-mail From: Gonzalo Pérez de Olaguer Córdoba <gpoc@iies.es> Newsgroups: es.comp.os.linux.programacion Subject: Re: WWW::Mechanize Date: Mon, 19 Mar 2007 02:50:18 +0100 Organization: escomposlinux.org Lines: 32 Message-ID: <20070319025018.3d86316a@petres.salonet.snet> References: <slrnevrbua.h1.natxo@tux.asenjo.nx> <slrnevrc42.1lg.natxo@tux.asenjo.nx> NNTP-Posting-Host: 84.77.244.205 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable X-Trace: hercules.cohp1 1174269019 22261 84.77.244.205 (19 Mar 2007 01:50:19 GMT) X-Complaints-To: newsmaster@news-17.escomposlinux.org NNTP-Posting-Date: Mon, 19 Mar 2007 01:50:19 +0000 (UTC) X-Newsreader: Sylpheed-Claws 1.0.4 (GTK+ 1.2.10; i386-pc-linux-gnu)