The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

WWW::Search::EbayUK - backend for searching www.ebay.co.uk

SYNOPSIS

    use WWW::Search;
    my $oSearch = new WWW::Search('EbayUK');
    my $sQuery = WWW::Search::escape_query("Bovine Spongiform Encephalitis");
    $oSearch->native_query($sQuery);
    while (my $oResult = $oSearch->next_result())
      { 
        print $oResult->url, "\n"; 
        print $oResult->title, "\n";
        print $oResult->description, "\n";
      }

DESCRIPTION

This class is a Ebay specialization of WWW::Search. It handles making and interpreting Ebay searches http://www.ebay.co.uk.

This class exports no public interface; all interaction should be done through WWW::Search objects.

NOTES

The search is done against CURRENT running auctions only.

The query is applied to TITLES only. See below for retrieving html from links.

The results are ordered youngest auctions first (reverse order of auction listing date).

In the resulting WWW::Search::Result objects, the description field consists of a human-readable combination (joined with semicolon-space) of the Item Number; number of bids; and high bid amount (or starting bid amount).

Extra information is available by following the links returned by: $oResult->url In such an instance extra information is returned that is not normally accessible from the result page. To cater for this, an extra details method is introduced:

  $oResult->details
  

Which stores the extra information in a hash.

OPTIONS

Search descriptions

To search titles and descriptions, add 'srchdesc' => 'y' to the query options:

  $oSearch->native_query($sQuery, { srchdesc => 'y' } );
  

To retrieve information from a specific ebay link, add 'follow_link' => '<http:// full URL>' to the query options:

  $sURL = '<http:// full URL>';
  $oSearch->native_query($sURL, { follow_link => "$sURL" } );
  

No escaping is required in this case.

Extra information is returned by this process. (Auction Start and End dates are a case in point.) Query the $oResult->details hash to retrieve this. E.g. the start date of the auction is retrieved like so:

  print $oResult->details->{'Start'}, "\n";

SEE ALSO

To make new back-ends, see WWW::Search.

BUGS

Doubt it. Please tell me if you find any!

AUTHOR

WWW::Search::EbayUK was Adapted by Andy Pritchard from Martin Thurn's Ebay module (pilchkinstein@hotmail.com).

Original WWW::Search::Ebay was written by Martin Thurn (mthurn@megapipe.net).

WWW::Search::EbayUK is maintained by Andy Pritchard

LEGALESE

THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.

VERSION HISTORY

2.01, 2003-03-14

Added extra prerequisites to the Makefile.PL to ensure all dependencies are covered.

2.00, 2003-02-26

Added follow_link functionality and new details method. This also supports the raw and title calls.

1.00, 2003-02-14

Adapted Ebay module for ebay.co.uk site

2.13, 2003-02-06

Fixed parsing for slightly-changed ebay.com pages

2.11, 2002-10-21

Fixed parsing for Buy-It-Now prices, and foreign currencies

2.08, 2002-07-24

Fixed parsing for new images in the results table

2.07, 2001-12-20

Restructured using parse_tree()

2.06, 2001-12-20

Handle new ebay.com output format

2.01

First publicly-released version.