Thanks, I've incorporated that. When I write the utf-8 as a file, do I also need to wrap it with that check?
######################################################################
+##################
sub write_file_utf8 {
my $outfilename= shift; # appears in browser tabs
my $outstr = shift; # file as a string
##################################################################
+##############
open OUTFILE, ">:utf8" , $outfilename
or die "cannot open >:utf8 $outfilename: $!";
#binmode STDOUT, ":utf8";
print OUTFILE $outstr, "\n";
close(OUTFILE);
} #sub
|