i found the Byte-order mask only for these encoding,
"FF FE" UCS-2LE or UTF-16LE
"FE FF" UCS-2BE or UTF-16BE
"EF BB BF" UTF-8
but i got a strange Byte order Mask while writing some utf8 format text into a utf8 format file
this is the BOM i got "e4 b8 ad " after i wrote in that utf8 format file.
check it for BOM in this site
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/intl/unicode_42jv.asp
the code i used is
use Encode;
use Encode::HanConvert;
$str8=gb_to_simp("中国的网页");#the str
+ing inside this is chinese characters
use utf8;
open OUT,">:utf8","D:\\output1.doc" or print "could not open";
print "\n",utf8::is_utf8($str8),"\n\n\n";
print OUT $str8;
close OUT;
no utf8;
Anyone tell me why this is happening,
i am wrinting in utf8 format only.but the Byte order mask shows different.why? help me in that.
The actual Byte order mask for utf8 is "EF BB BF".