WWW-MobileCarrierJP

 view release on metacpan or  search on metacpan

lib/WWW/MobileCarrierJP/DoCoMo/UserAgent.pm  view on Meta::CPAN

                uc $_;
            };

            my $ua = sub {
                for my $col (@cols) {
                    $col = $col->as_HTML;
                    next unless $col =~ /DoCoMo/;

                    $col = (
                        grep {/DoCoMo/}
                        split m[(?:&nbsp;|<br\s*/>|\r|\n)]i, $col
                    )[0]; # XXX: 複数あるときは一番最初のがブラウザ
                    $col =~ s/ *(.+//;
                    $col =~ s/<[^><]+>//g; # remove tags
                    $col =~ s/(&#xA0.*)$//;
                    $col =~ s/^\s*//;
                    $col =~ s/\s*$//;
                    return $col;
                }
            }->();
            debug ("$model - $ua");



( run in 1.460 second using v1.01-cache-2.11-cpan-71847e10f99 )