On Wed, 26 Jul 2006 18:26:49 -0400, Tristan Fiedler wrote: > Hello All, > > I posted the following on PerlMonks but have not found a solution. > Could someone please comment on solutions to the following error. I am > using the Library of Congress driver to look up book info based on ISBN > numbers. I am not clear on how to combine the driver pm file with the > script, etc. I have also tested several other Driver files. > > use WWW::Scraper::ISBN::Driver; > use WWW::Scraper::ISBN::LOC_Driver; > $driver = WWW::Scraper::ISBN::LOC_Driver->new(); > $driver->search("0764516965"); > $driver->verbosity(1); > my $book = $driver->book(); > print $book('title');
That line should be: print $book->{title}; You should also be checking to see whether the search was successful. > print $driver->error; > > and here is the result : > > Can't use an undefined value as a symbol reference at isbn_lookup2.pl > +line 9. {the 'title' line} -- Peter Scott http://www.perlmedic.com/ http://www.perldebugged.com/ -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>