Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/unreal4u/string-operations
Collection of functions that deals with strings
https://github.com/unreal4u/string-operations
Last synced: about 2 months ago
JSON representation
Collection of functions that deals with strings
- Host: GitHub
- URL: https://github.com/unreal4u/string-operations
- Owner: unreal4u
- Created: 2013-10-01T19:24:25.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2014-11-03T20:52:49.000Z (about 10 years ago)
- Last Synced: 2024-10-12T05:09:20.901Z (3 months ago)
- Language: PHP
- Homepage:
- Size: 383 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[![Latest Stable Version](https://poser.pugx.org/unreal4u/string-operations/v/stable.png)](https://packagist.org/packages/unreal4u/string-operations)
[![Build Status](https://travis-ci.org/unreal4u/string-operations.png?branch=master)](https://travis-ci.org/unreal4u/string-operations)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/unreal4u/string-operations/badges/quality-score.png?s=bda9bffddbd3a8fb7f24782c42dfd4d57ea0d2d8)](https://scrutinizer-ci.com/g/unreal4u/string-operations/)
[![License](https://poser.pugx.org/unreal4u/string-operations/license.png)](https://packagist.org/packages/unreal4u/string-operations)stringOperations.php
======Credits
--------This class is made by unreal4u (Camilo Sperberg). [unreal4u.com/](http://unreal4u.com/)
About this class
--------* Originally conceived to be a receiver of all loose string-related functions that I've made throughout the years
* Later also a playground to learn about multibyte capabilities of stringsDetailed description
---------This package is a collection of functions related to string manipulation.
Basic usage
----------include('src/unreal4u/stringOperations.php');
$stringOperations = new unreal4u\stringOperations();
$result = $stringOperations->truncate('this is a bigger text', 15);* Congratulations! Result will have a truncated string, compatible with UTF-8 characters:
this is a bigger...
* Please see examples and PHPUnit tests for more options and advanced usageComposer
----------This class has support for Composer install. Just add the following section to your composer.json with:
{
"require": {
"unreal4u/string-operations": "@stable"
}
}Now you can instantiate a new stringOperations class by executing:
require('vendor/autoload.php');$stringOperations = new unreal4u\stringOperations();
Pending
---------
* Search for more loose functions spattered around my codebase
* Improve the usage of the internal used charset
* Consistent usage of the class and it subcomponents (UTF-8 in createSlug)
* Multiple arguments for separator in truncate function
* Use transliterate instead of htmlentities (Will produce BC!)Version History
----------* 0.1:
* Created class
* 0.1.1:
* Documentation fixes
* 0.2.0:
* Added decomposeCompleteEmail() function and unit tests for it
* 0.2.2:
* Documentation update
* 0.3.0:
* Composer compatibility
* Documentation and examples update
* 0.3.1:
* Renamed repo and moved PHPUnit as dependency
* 0.3.2:
* Travis-CI support
* Gitattributes
* Documentation fixes
* 1.0.0:
* Truncate function improvements and BC breaks
* This function can now search backwards in the string
* This function now supports multiple separators
* Excluded some things from the auto generated release packages
* 1.1.0:
* Class doesn't rely anymore on imap functions, so no more need for imap extension!
* Update to PHPUnit 4.0
* Added PHP 5.3 to the battery testContact the author
-------* Twitter: [@unreal4u](http://twitter.com/unreal4u)
* Website: [http://unreal4u.com/](http://unreal4u.com/)
* Github: [http://www.github.com/unreal4u](http://www.github.com/unreal4u)