bknasmueller/php-truncate

Abbreviates a string to a given length using a custom trailing string.

0.1.0 2019-05-05 11:10 UTC

This package is not auto-updated.

Last update: 2024-10-01 13:26:16 UTC


README

A PHP string truncation library with multibyte support.

Usage

StringTruncate::truncate('abcdefghijklmnopqrstuvwxyz', 10);

Installation

Include the following in your composer.json file:

"require": {
    "bknasmueller/php-truncate": "~0.1.0"
}