Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cchlorine/pangu.php
Paranoid text spacing in PHP
https://github.com/cchlorine/pangu.php
Last synced: 2 months ago
JSON representation
Paranoid text spacing in PHP
- Host: GitHub
- URL: https://github.com/cchlorine/pangu.php
- Owner: cchlorine
- License: mit
- Created: 2015-07-29T20:09:44.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-08-20T14:24:45.000Z (over 6 years ago)
- Last Synced: 2024-05-19T01:56:48.908Z (8 months ago)
- Language: PHP
- Size: 15.6 KB
- Stars: 80
- Watchers: 3
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- php-awesome - pangu.php - 自动添加文本的空格 (类库 / 文本处理)
README
pangu.php
===
![TravisCI](https://travis-ci.org/Kunr/pangu.php.svg)Paranoid text spacing for good readability, to automatically insert whitespace between CJK (Chinese, Japanese, Korean) and half-width characters (alphabetical letters, numerical digits and symbols).
* Go version: [pangu.go](https://github.com/vinta/pangu)
* Java version: [pangu.java](https://github.com/vinta/pangu.java)
* JavaScript version: [pangu.js](https://github.com/vinta/paranoid-auto-spacing)
* Node.js version: [pangu.node](https://github.com/huei90/pangu.node)
* Object-C version [pangu.objective-c](https://github.com/Cee/pangu.objective-c)
* Python version: [pangu.py](https://github.com/vinta/pangu.py)
* Ruby version: [pangu.rb](https://github.com/dlackty/pangu.rb)## Installation
Using composer
```
composer require kunr/pangu.php
```Or manually
```
git clone https://github.com/Kunr/pangu.php.git
```## Usage
Require `pangu.php`
```
require 'pangu.php';
echo pangu('Jackie的鼻子有幾個?123個!'); // Jackie 的鼻子有幾個?123 個!
```Or
Use `pangu-cli.php`
```
php pangu-cli.php "Jackie的鼻子有幾個?123個!" //// Jackie 的鼻子有幾個?123 個!
```## License
Released under the MIT License.