webpatser / laravel-sanitize
Laravel package to sanatize a string for use as URL's. It uses the PHP Normalizer class and fills whitespace with dashes.
Installs: 36 017
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 2
Forks: 2
Open Issues: 2
Type:laravel-library
Requires
- php: >=5.3.0
This package is auto-updated.
Last update: 2024-10-24 04:48:39 UTC
README
Laravel package to sanitize a string for use in URL's
Installation
Add webpatser/laravel-sanitize
to composer.json
.
"webpatser/laravel-sanitize": "dev-master"
Run composer update
to get the latest version of Sanitize.
Edit app/config/app.php
and add the alias
'aliases' => array(
'Sanitize' => 'Webpatser\Sanitize\Sanitize',
)
Usage
Sanitize::string('Sanitize me please!'); // sanitize-me-please
Notes
It uses the PHP Normalizer class and does some extra magic, and wraps it in the Laravel 4 grand scheme of things.