open FILE, ">$ENV{'DOCUMENT_ROOT'}/some_path/some_other_path/some_pass_file" or die $!; print FILE "webmaster:realm made by greek chars!:" .Digest::MD5::md5_hex("webmaster:realm made by greek chars!:password") ."\n"; close FILE; #### open FILE, ">:encoding(iso-8859-1)", "$ENV{'DOCUMENT_ROOT'}/some_path/some_other_path/some_pass_file" or die $!; print FILE "webmaster:realm made by greek chars!:" .Digest::MD5::md5_hex("webmaster:realm made by greek chars!:password") ."\n"; close FILE;