This package is abandoned and no longer maintained. No replacement package was suggested.

Simple PHP Slug generator

1.0.0 2022-09-21 21:44 UTC

This package is auto-updated.

Last update: 2023-06-21 23:35:29 UTC


README

Tests status GitHub tag (latest SemVer)

Simple library for building a slugs out of strings.

Usage:

use Praetorian\Slugger\Slugger;

$slugger = new Slugger();
echo $slugger->slugify('sample$$@#%$ test ąęćźż'); //sample-test-aeczz
echo PHP_EOL;
echo $slugger->slugify('sample$$@#%$ test ąęćźż', divider: '_'); //sample_test_aeczz

Contribution

Any pull requests or issues reported are more than welcome.

License

MIT