I cant seem to find any documentation on how to write a text file to the
filesystem with an explicit encoding type? Can someone point me in the
right direction? Its a simple text file, but it *needs* to be UTF-16.
I cant seem to find any documentation on how to write a text file to the
filesystem with an explicit encoding type? Can someone point me in the
right direction? Its a simple text file, but it *needs* to be UTF-16.
Cheers
Tim
require 'iconv'
converter = Iconv.new("UTF-16", "ISO-8859-15")
utf_16_str = converter.iconv('hello world')
p utf_16_str