Hire a senior Perl / Python programmer today; download my up-to-date resume (PDF)
John Bokma Perl
freelance Perl programmer

Comments: Currency converter interface

4 comments

The Perl program given on this page is an example, for educational purposes only, of how to use the LWP::UserAgent and HTML::TreeBuilder modules to download a web page and extract information from it. Don't use this program to automatically extract data from XE.com, since the site strictly forbids this. The Perl program is just a simple example to get you started on how to fill in a web form and using the POST method to get the result back.

Read the rest of Currency converter interface.

Comments

I'm a learn by example kind of guy, and I searched the web pretty hard for a working example of how to use the post() method contained in the LWP::UserAgent module. I found lots of links to MANpages, but precious few examples of working code.

My search finally led me to your example; one that utilizes just the method I was looking to implement in my own code.

The way you presented the code allowed me to easily understand how the method worked and what I neeeded to do to use it for my own application.

I had my script up and running in about two minutes, after having spent a good 20 minutes beforehand struggling to understand.

Thanks!

By the way, my script extracts IEEE MAC address ownership information from the IEEE online database search page.

Posted by W.Watts at 13:35 GMT on 26 January 2006

Your website is great! Its very nice to see websites of other Perl lovers. Perl rules!!

Posted by Arul at 20:32 GMT on 21 February 2007

It seems like XE.com has changed their page layout this weekend and I can no longer use the script. Sadly, I'm not a Perl wiz and can't change the code myself.. An updated script would be most welcome!

TIA

Posted by Lars at 09:55 GMT on 26 February 2007

Thanks Lars, I have put it on my todo list for this week.

Posted by John Bokma at 00:22 GMT on 6 March 2007

Post a comment

Note that your comment doesn't show up immediately. I review each comment before I add it to this site.

Check the Follow this page option if you want to receive an email each time a comment is posted to this page, including yours. A link to turn this option off will be included with each email.

Internet adresses will be converted automatically. You can use the following notation to specify anchor text for a link: [url=http://example.com/]example text[/url].