PHP Classes
elePHPant
Icontem

Chinese Master: Detect and convert text in Chinese

Recommend this page to a friend!
  Info   View files Documentation   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2017-06-06 (3 months ago) RSS 2.0 feedNot yet rated by the usersTotal: 42 All time: 8,980 This week: 548Up
Version License PHP version Categories
chinese-master 1.0Custom (specified...5Localization, PHP 5, Text processing
Description Author
This package is specific mainly for applications used in China China .

This class can detect and convert text in Chinese.

It can take a text string and detects if it is in simplified Chinese or traditional Chinese.

The class can also convert text between simplified and traditional Chinese encodings.

Innovation Award
PHP Programming Innovation award nominee
June 2017
Number 6
Chinese is a language that can be represented in either traditional and simplified formats.

This class can detect when a text string is represented in either format and convert the text between each of the format.

Manuel Lemos
  Performance   Level  
Name: Peter Kahl <contact>
Classes: 32 packages by
Country: Hong Kong Hong Kong
Age: ???
All time rank: 6854 in Hong Kong Hong Kong
Week rank: 17 Up1 in Hong Kong Hong Kong Up
Innovation award
Innovation award
Nominee: 18x

Details

Chinese Master

Processes Chinese text.

Usage

Is string using traditional Chinese script?

use peterkahl\ChineseMaster\ChineseMaster;

if (ChineseMaster::isTraditional('???')) {
  echo 'traditional';
}
else {
  echo 'simplified';
}

# traditional

Convert traditional to simplified

use peterkahl\ChineseMaster\ChineseMaster;

echo ChineseMaster::trad2simp('???'); # ???

Convert simplified to traditional

use peterkahl\ChineseMaster\ChineseMaster;

echo ChineseMaster::simp2trad('???'); # ???
  Files folder image Files  
File Role Description
Files folder imagesrc (1 file)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files  /  src  
File Role Description
  Plain text file ChineseMaster.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:42
This week:0
All time:8,980
This week:548Up