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

NAME

WWW::Search::HotFiles - class for searching ZDnet HotFiles

SYNOPSIS

require WWW::Search; $search = new WWW::Search('HotFiles');

DESCRIPTION

Class for searching ZDnet HotFiles (shareware, freeware) via Lycos. http://www.hotfiles.lycos.com.

If you use the raw method for this backend you will need to include a "<p>" at end of your print statement, example: print $result->raw(), "<p>\n";

This is so that each result returned will have a HTML break since the HTML is being extracted from tables, and, there is no <p> or <br> trailing returned HITS to properly format the results. No BIG deal really.

Print optioins: Using score will return nice star images for rating purposes at end of each description line for each HIT if desired.

Using index_date will return the files date.

Raw returns description, star rating image, date, downloads, OS version.

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

USAGE EXAMPLE

 One of several print samples for this backend (this is a WebSearch
 example):

 print <<END;

 <FONT SIZE=2><B>$count. <a href="$prefix$_">$result->{'title'}</A></B><BR>
 $result->{'description'} 
 $result->{'index_date'} $result->{'score'}<P></SMALL></FONT>

 END
         

SEE ALSO

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

HOW DOES IT WORK?

native_setup_search is called before we do anything. It initializes our private variables (which all begin with underscores) and sets up a URL to the first results page in {_next_url}.

native_retrieve_some is called (from WWW::Search::retrieve_some) whenever more hits are needed. It calls the LWP library to fetch the page specified by {_next_url}. It parses this page, appending any search hits it finds to {cache}. If it finds a ``next'' button in the text, it sets {_next_url} to point to the page for the next set of results, otherwise it sets it to undef to indicate we're done.

AUTHOR

Maintained by Jim Smyser <jsmyser@bigfoot.com>

TESTING

Lycos can return pricky test results depending what time the test are run (server load?).

    $search_engine = 'HotFiles';
    $maintainer = 'Jim Smyser <jsmyser@bigfoot.com>';

    $file = 'test/HotFiles/zero_result'; 
    $query = $bogus_query; 
    test($mode, $TEST_EXACTLY); 
     
    $file = 'test/HotFiles/one_page_result'; 
    $query = 'Med' . 'icine';
    test($mode, $TEST_RANGE, 2, 25);
      
    $file = 'test/HotFiles/multi_page_result'; 
    $query = 'Ch' . 'ess';
    test($mode, $TEST_GREATER_THAN, 49); 

COPYRIGHT

The original parts from John Heidemann are subject to following copyright notice:

Copyright (c) 1996-1998 University of Southern California. All rights reserved.

Redistribution and use in source and binary forms are permitted provided that the above copyright notice and this paragraph are duplicated in all such forms and that any documentation, advertising materials, and other materials related to such distribution and use acknowledge that the software was developed by the University of Southern California, Information Sciences Institute. The name of the University may not be used to endorse or promote products derived from this software without specific prior written permission.

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.