[prog] Writting a program to automatically fetch webpages, and fill in forms.

Jacinta Richardson jarich at perltraining.com.au
Thu Mar 24 14:31:40 EST 2005


Sue Stones wrote:

> Thanks for all your suggestions I will investigate them all.  At this 
> stage I am wondering about relative ease of installing the system that I 
> use.
> 
> That is if I use perl does the user need to install perl on their 
> computer, if I use python or URL, does the user need to install that on 
> their system.  If they do how big is the install, and how easy is it for 
> people who find using a search engine a very technical exercise?

For Perl you might want to consider PAR (Perl Archive Tool).  This allows you to 
bundle up your programs and their dependancies into a single file.  This can 
include a binary for Perl or not, as you choose:

            http://par.perl.org/index.cgi

If you expect that the majority of your uses will be using Windows (and you 
don't like PAR) you might find it efficient to purchase the Active State 
Development Kit for Perl (or appropriate parts thereof) and use their bundling 
system.  This will give you a Windows-style executable which just "works" 
without having Perl installed.

There is an Active State Dev Kit for Python too (I think it's the same one) and 
that allows you to bundle your Python programs into executables too.

	  http://www.activestate.com

> Basically I need to submit search terms to a search engine and retrieve 
> the results of the search.  My preference is to retrieve the count and 
> the links independently.  tie if a search has matched 1024 articles I 
> want to refine the search to about 7 articles before I retrieve any 
> links to those articles.

If your search engine is Google then you might want to look at the Google 
modules available for Perl
	http://search.cpan.org/search?query=google&mode=all

in particular Net::Google, Net::Google::Search and WWW::Scraper::Google.

Note that you may have to register for a Google Web API account and have a valid 
Google API license key to do this kind of thing.

All the best,

    Jacinta

-- 
    ("`-''-/").___..--''"`-._          |  Jacinta Richardson         |
     `6_ 6  )   `-.  (     ).`-.__.`)  |  Perl Training Australia    |
     (_Y_.)'  ._   )  `._ `. ``-..-'   |      +61 3 9354 6001        |
   _..`--'_..-_/  /--'_.' ,'           | contact at perltraining.com.au |
  (il),-''  (li),'  ((!.-'             |   www.perltraining.com.au   |




More information about the Programming mailing list