iconv.new('cp932', 'utf-8')与iconv.new('shift_jis', 'utf-8')的区别
iconv.new('shift_jis', 'utf-8')不支持以下的格式:
課№001-18 xxxxxxx 而只能把字符窜中的№换成no.才行
但是iconv.new('cp932', 'utf-8')支持.
2.半角全角转换
看下面的代码:
require "jcode"
$cov.iconv(year.to_s.tr('0-9', '0-9') + '年' + month.to_s.tr('0-9', '0-9') + '月度作業報告書')