NAME
Finance::Currency::Convert::Yahoo - convert currencies using Yahoo
SYNOPSIS
use Finance::Currency::Convert::Yahoo;
$Finance::Currency::Convert::Yahoo::CHAT = 1;
$_ = Finance::Currency::Convert::Yahoo::convert(1,'USD','GBP');
print "Is $_\n" if defined $_;
DESCRIPTION
Using Finance.Yahoo.com, converts a sum between two currencies.
USE
Call the module's &convert
routine, supplying three arguments: the amount to convert, and the currencies to convert from and to.
Codes are used to identify currencies: you may view them in the values of the %currencies
hash, where keys are descriptions of the currencies.
In the event that attempts to convert fail, you will recieve undef
in response, with errors going to STDERR, and notes displayed if the modules global $CHAT
is defined.
In more detail, the module accesses http://finance.yahoo.com/m5?a=amount&s=start&t=to
, where start
is the currency being converted, to
is the target currency, and amount
is the amount being converted. The latter is a number; the former two codes defined in our %currencies
hash. (Last checked 07 December 2001).
EXPORTS
None by default.
REVISIONS
Please see the enclosed file CHANGES.
SEE ALSO
LWP::UserAgent, HTTP::Request, HTML::TokeParser.
AUTHOR
Lee Goddard lgoddard@cpan.org.
COPYRIGHT
Copyright (C) Lee Goddard, 2001 - All Rights Reserved.
This library is free software and may be used only under the same terms as Perl itself.