in reply to Unicode problem

Make sure that you have the encoding you are looking for:

use Encode; print join ('\n', Encode->encodings());

You might also want to check the value of:

is_utf8($_);

Finally, it cannot hurt anything but performance to do:

$uni = encode_utf8($_);

The intelligent reader will judge for himself. Without examining the facts fully and fairly, there is no way of knowing whether vox populi is really vox dei, or merely vox asinorum. -- Cyrus H. Gordon