Input content is an html fragment copied from a webkit window, for example

It displays correctly in a web set using UTF-8.
What I want to do is replace all the tags, I use this single line font:
perl -i -pe "s/<img.+?>//g"
Input is rich text that I copied to my clipboard and redirected to this one-line by another program, maybe this is something like:
echo "rich html text" | perl -i -pe "s/<img.+?>//g"
Well, it removes tags <img>, but all Unicode characters get corrupted after wildcard.

I am on Windows 7, locale En - US. The cmd code page is already installed in UTF-8. It does not work even if I pass the parameter -C.
Is there a way to save the code as single-line while it works for Unicode input?
source
share