gbk编码在线转换工具_TOOLFK工具-在线汉字/字母/人民币/简繁体转换工具
生活随笔
收集整理的這篇文章主要介紹了
gbk编码在线转换工具_TOOLFK工具-在线汉字/字母/人民币/简繁体转换工具
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
本文要推薦的[TOOLFK]在線漢字/字母/人民幣/簡(jiǎn)繁體轉(zhuǎn)換工具,提供簡(jiǎn)繁體在線轉(zhuǎn)換、人民幣大寫轉(zhuǎn)換、字母大小寫互轉(zhuǎn)、漢字轉(zhuǎn)拼音在線日常使用工具。
網(wǎng)站名稱:ToolFk
網(wǎng)站鏈結(jié):https://www.toolfk.com/
工具鏈接:https://www.toolfk.com/tool-online-convert
代碼教學(xué)
本工具[在線漢字/字母/人民幣/簡(jiǎn)繁體轉(zhuǎn)換工具 ]依賴的代碼庫(kù)為(可查看TOOLFK網(wǎng)站源碼進(jìn)行查看)
http://www.toollibs.com/togglecase transverter.js / pinyin_dict_withtone.js / pinyin_dict_polyph / rmb.js / ec-do.jsSTEP 1 在線漢字轉(zhuǎn)拼音工具
STEP 2 在線簡(jiǎn)繁體在線轉(zhuǎn)換工具
STEP 3 在線人民幣大寫轉(zhuǎn)換工具
STEP4 在線字母大小寫互轉(zhuǎn)工具
STEP5
在線轉(zhuǎn)換工具核心代碼如下
#大小寫互換 function toggles(type){var value = togglecase_s.getValue();if(value==''){return layer.msg(NOT_EMPTY);}var result = '';if(type == 1){result = ecDo.toggleCase(value);}else if(type==2){result = ecDo.firstWordUpper(value);}else{result = ecDo.firstWordLower(value);}togglecase_t.setValue(result); } #轉(zhuǎn)RMB $('.btn_fun_rmb').click(function (e) {e.preventDefault();var value = rmb_s.getValue();console.log("value = =="+value);if(value==''){return layer.msg(NOT_EMPTY);}rmb_t.setValue(trans(value)); });#簡(jiǎn)繁互換 function trans(_type){var value = trans_s.getValue();if(value==''){return layer.msg(NOT_EMPTY);}trans_t.setValue(transverter({type:_type,str:value})); } #獲取漢字拼音 function getPinyin(){var type = parseInt($('input[name="pinyin_option"]:checked').val());var isStartDuoyin = $('input[name="start_duoyin"]:checked').val() ? true : false;var text = $.trim(pinyin_s.getValue());if(text == ''){layer.msg(NOT_EMPTY);return;}var result = '';switch (type){case 0:result = pinyinUtil.getPinyin(text, ' ', true, isStartDuoyin);break;case 1:result = pinyinUtil.getPinyin(text, ' ', false, isStartDuoyin);break;case 2:result = pinyinUtil.getFirstLetter(text, isStartDuoyin);break;}var html = result;if(result instanceof Array){html = '';result.forEach(function(val,i){if(i >= 10)return;html += val + "nn";});}pinyin_t.setValue(html);}總結(jié)
以上是生活随笔為你收集整理的gbk编码在线转换工具_TOOLFK工具-在线汉字/字母/人民币/简繁体转换工具的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: elupload获取文件名与路径_Uip
- 下一篇: clickhouse官方文档_click