See Mojibake for modules and routines that deal with this.
In reply to Re: Encode double time by Corion in thread Encode double time by arivu198314