in reply to scrape a webpage

You haven't specified what you're using to parse the HTML, here is an example using Mojo::DOM:

#!/usr/bin/perl use strict; use warnings; use Mojo::DOM; my $html = '<td class="fex_standardblack_font_small" bgcolor="white"> <input id="chkEquipment" name="chkEquipment" value="72" type="checkbox +"> 4WD/AWD </td>'; my $dom = Mojo::DOM->new( $html ); print $dom->at('#chkEquipment')->val;

The module is well documented. If this isn't what you're looking for you may need to ask a better question. How do I post a question effectively?.

Replies are listed 'Best First'.
Re^2: scrape a webpage
by Anonymous Monk on May 22, 2017 at 13:00 UTC
    # ===== I'm using ===================== use WWW::Mechanize::Firefox qw(); use HTML::TreeBuilder::LibXML qw();

      Look at $mech->value(); from the WWW::Mechanize::Firefox documentation. You could have saved time by specifying these modules in your question.

        I read $mech->value() doc but still can't figure out what to do. If I don't "trim" $B, I get this printout: للللل4WD/AWD I'm lost.