Depending on what you are trying to accomplish with the data you extract, you may want to also look at HTML::Form as an alternative to HTML::TreeBuilder. I have used both and found HTML::Form much easier to work with for both parsing forms from HTML and generating POST data.
Update: Fixed cut-and-paste error. Second link should have been to HTML::TreeBuilder.