Str::slug

Posted on November 25, 2016

The Str::slug function generates a URL friendly “slug” from the given string.

Example usage

$title = Str::slug('Lolita Framework', '-');
// lolita-framework

$title = Str::slug('Lolita Framework', '_');
// lolita_framework

Parameters

string $title

string $separator

Return Value

string

0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *