use strict; use warnings; use HTML::Parser; open OUT, '>', 'delme1.txt'; print OUT <

The use of the Porter and Ale is more prevalent in England. In the United States ½ Old and ½ New Ale is usually used when this drink is called for, unless otherwise specified.

STR close OUT; my $p = HTML::Parser->new( api_version => 3, text_h => [\&text, "dtext"], ); $p->parse_file ('delme1.txt'); sub text { my($origtext) = @_; $origtext =~ s/½/\½/g; print $origtext; } #### The use of the Porter and Ale is more prevalent in England. In the United States ½ Old and ½ New Ale is usually used when this drink is called for, unless otherwise specified.