摘要: #定义一个UTF-8=>GBK的方法def encoding inStr Iconv.iconv("GBK","UTF-8",inStr)end#定义一个GBK=>UTF-8的方法def unencoding inStr Iconv.iconv("UTF-8","GBK",inStr).joinend学习参考:http://www.kuqin.com/rubycndocument/man/addlib/Iconv.html#Iconv.2eiconvIconv 类类方法Iconv.new(to, fro 阅读全文
posted @ 2013-07-31 10:59 dami.van 阅读(1357) 评论(0) 推荐(0) 编辑