getBytes in perl ?!?

[email protected] ((PerlDiscuss - Perl Newsgroups and mailing lists))
Newsgroups perl.unicode
Organization PerlDiscuss.com
Message-ID <[email protected]>
Hello,

Do you know if there is in Perl the function "getBytes" in Java ?
I would like to convert a "string" to bytes in perl.

the idea could be :
$mystring="Hello EveryBody. How are you ?";
$mybytes = getBytes($mystring);
$mybytes="0x3C3F786D6C2076657273696F6E3D22312E"; #something like

Perl Version : 5.6.1
Apparently, I do not have the "Encode.pm" in my libraries.

Thank you by advance,
Regards,
jc
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.