Re: Opening & writing to UTF-8 files; copyright symbol again -- solution

2015-11-16 Thread Colin Campbell
On Fri, Nov 13, 2015 at 10:05:01PM +, Highsmith, Anne L wrote: > I should probably say, "apparent solution" 'cause character set issues never > seem to end. > > However, combining Jon Gorman's recommendation with some Googling, I get: > > my $outfile='4788022.edited.bib'; > open (my

RE: Opening & writing to UTF-8 files; copyright symbol again -- solution

2015-11-16 Thread PHILLIPS M.E.
> You can set the correct encoding succinctly on opening files > e.g. open my $fh, '>:encoding(UTF-8)', $outfile You might also see this even more succinct variant: open my $fh, '>:utf8', $outfile though technically speaking, that will not give you guaranteed conformant UTF-8 because it could

RE: Opening & writing to UTF-8 files; copyright symbol again -- solution

2015-11-16 Thread PHILLIPS M.E.
The copyright symbol is not one of the characters for which there are two representations. One thing that can confuse people about Unicode is the distinction between the “code point”[1] and the representation of the code point in the various Unicode transformation formats such as UTF-8,

RE: Opening & writing to UTF-8 files; copyright symbol again -- solution

2015-11-16 Thread PHILLIPS M.E.
> However, combining Jon Gorman's recommendation with some Googling, I get: > > my $outfile='4788022.edited.bib'; > open (my $output_marc, '>', $outfile) or die "Couldn't open file $!" ; > binmode($output_marc, ':utf8'); > > The open statement may not be quite correct, as I am not familiar with