Special effects for converting Chinese characters to PinYin Based on jQuery. Hz2Py. js plug-in
JQuery. hz2Py. the conversion of Chinese characters to PinYin implemented by the js plug-in is a very practical online Conversion Function. This plug-in has packaged Chinese characters into a plug-in library, and the call time is very simple, only one method can be called for conversion.
You can implement conversion of Chinese characters into pinyin code based on jQuery. This is a special Chinese character-to-pinyin Effect Based on the jQuery. Hz2Py. js plug-in. The plug-in is automatically downloaded. Use the following method (modify the jq import path ).
?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
<Html> <Title> converting Chinese characters into pinyin codes based on jQuery </title> <Style type = "text/css"> # Content { Border: 1px # dbdbdb solid; Width: 700px; Height: 50px; Padding: 10px; Font-size: 13px; Line-height: 23px; Letter-spacing: 15px; } # Show { Border: 1px # dbdbdb solid; Width: 700px; Height: 50px; Padding: 10px; Font-size: 12px; Color: # FF0000; Line-height: 23px; Margin-top: 2px; Letter-spacing: 1px; Overflow-x: hide; Overflow-y: auto; } # Show { Color: # FF0000; Font-size: 13px; Font-weight: bold; } </Style> <Script src = "js/jquery. min. js"> </script> <Script type = "text/javascript" src = "js/jQuery. Hz2Py-min.js"> </script> <Script type = "text/javascript"> $ (Function (){ $ ("# Content"). live ("keyup keydown change blur", function (){ $ ("# Show"). val ($ (this). toPinyin ()); }); }); </Script> </Head> <body> <Center> Enter the Chinese character <textarea id = "content"> </textarea> <textarea id = "show"> </textarea> </Center> </body> |
The above is all the content of this article. I hope you will like it.
Note <>: For more exciting tutorials, please pay attention to the help house programming