in terms of compatibility and performance.
Pinyin. php contains a total of 25961 characters, including 20902 basic Chinese characters (Unicode code 0x4e00-0x9fa5) and 6582 Chinese characters (Unicode code 0x3400-0x4db5). Only the Pinyin of 5059 uncommon characters is collected, the word list does not contain the 5059 uncommon words. Compared to my previous PHP Chinese
How Linux systems change the character set supportHow to set Linux system Chinese Language, this is a lot of small partners in the beginning of the use of Linux, will encounter a problem, is the terminal input command echo when the Chinese display garbled. This situation typically occurs because the Chinese Language pa
Web page Production WEBJX article introduction: Design font: The spirit and aura of Chinese characters.
The gas field of Chinese characters
Shang (Digidea Lee)
As the saying goes, the word as the person, through a person to write the word to our feelings, from the indirect can see his bearing, for people, this is true. and printing fonts are the same, the difference between different fonts
To make character or string substitutions in JS we can use the Replace () method to replace some characters with some character in a string, or to replace a substring that matches a regular expression.
Stringobject.replace (regexp/substr,replacement)
Replace with the Replace regular expression
can also be replaced directly with replace
For
PHP Chinese character to pinyin source code (GB2312 class library, supporting about 6000 Chinese characters)
In a recent project, php is used as the development language for front-end data. in order to sort data by letter, Chinese pinyin must be extracted, I used this project to write a script for converting
Yesterday, in writing code I encountered a problem of Chinese string interception, originally wanted to use substr (), but this is used in a single-byte character, for multibyte-encoded Chinese characters or other language character, this function may not be used, and will easily intercept garbled to! Now put my work r
Chinese characters are encoded in double-byte, and for Chinese characters and single-byte characters, if the target intercept string contains only an odd number of single-byte characters, then the problem of half Chinese characters will appear. As shown below:(1) No. 2nd South Guo Lu, Tianshui Qinzhou District (ICBC Qi Li dun sub-branches?) -- contains numeric ch
Chinese character verification code is The imitation of QQ registration verification code, using this type of verification code to verify user input, compared to the traditional verification code input, not only increased the difficulty of machine identification (need to find the corresponding text sequence and location), and make the real user operation is more simple and convenient, just click on the diag
public class Text {Java one character judging all is Chinese including punctuationPrivate static Final Boolean Ischinese (char c) {Character.unicodeblock UB = Character.UnicodeBlock.of (c);if (UB = = Character.UnicodeBlock.CJK_UNIFIED_IDEOGRAPHS|| UB = = Character.UnicodeBlock.CJK_COMPATIBILITY_IDEOGRAPHS|| UB = = Character.UnicodeBlock.CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A|| UB = = Character.UnicodeBlock.GENE
Converts Chinese characters to pinyin and uppercase letters of each Chinese character, such as dalian. I convert them to dalian, and convert them to D and l to L, in addition, other letters are shared in lower case: more Chinese characters are converted into pinyin, and each Chines
Parses a string (Chinese Character Unicode encoding) into Chinese characters and unicode encoding
Prerequisites: the server uses a. Net website, while the android client is developed in Java. The data transmission format used again is in Json format.
Generally, projects are developed using the java language on the server. Therefore, although Json format is used f
Java General Chinese judgments are based on regular expressions
Pattern pattern = Pattern.compile ("[\u4e00-\u9fcc]+");
SYSTEM.OUT.PRINTLN (Pattern.matcher (str). find ());
Or
System.out.println (Str.matches ("[\u4e00-\u9fcc]+"));
this way there will be some obscure Chinese characters can not be recognized, but also can not match the Chinese symbo
[Leaf function sharing 290] Chinese character to PinYin function classification: SQL function sharing series people read comments (0) Add to favorites report/* response function: fn_getpinyin description: conversion of Chinese characters to PinYin (non-data table version): DBO. fn_getpinyin ('People's Republic of China') = zhonghuarenmingongheguo Author: Liu Xian
Converts Chinese characters to pinyin, and converts the first letter of each Chinese character to uppercase, for example, dalian, dalian, D, l, and other letters to lowercase.
Reply to discussion (solution)
Can you help me solve this problem? Solution
The code for converting Chinese characters to pinyin in the pin
This is a statistical string (containing Chinese characters) length method:var str = ' 223,344 '; alert (Getstrlen (str)) function Getstrlen (str) {var json = {Len:0};var re =/[\u4e00-\u9fa5]/; A regular expression that determines whether the kanji for (var i = 0; i This is the method of judging whether it is a Chinese character:var str = ' 223,344 '; var end = (/[\u4e00-\u9fa5]/g). Test (str); This is a
Install the Chinese Language pack:Yum Groupinstall Chinese-supportModify the character encoding configuration and create it without this file:vim/etc/sysconfig/i18nThe following changes are included:Lang= "ZH_CN. Gb18030″Supported= "ZH_CN. Utf-8:zh_cn:zh:en_us. Utf-8:en_us:en "Sysfont= "Latarcyrheb-sun16″The i18n file is used to set the system language, such as:
/**
*
A Chinese character is counted as two digits, an English alphabet is counted, and the string length of the mixed Chinese and English characters is calculated. String: String str = "I am not good Java";
* @author New/new *
/public class Teststr2 {public
static void Main (string[] args)
{
String str = "I'm not good at Java ";
int n= calculateplac
Converts Chinese characters to pinyin and uppercase letters of each Chinese character, such as dalian. I convert them to dalian, and convert them to D and l to L, in addition, other letters are shared in lower case: more -- convert Chinese characters into pinyin, and make the first letter of each
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.