May be the following conversion will satisfy you
$xml_native =~ s/([^\w\s])/'&#'.ord($1).';'/ge;
In reply to Re: How to convert <,&,>,",' into XML <,&,>," ..
by ccn
in thread How to convert <,&,>,",' into XML <,&,>," ..
by gasho
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |