阅读背景:

如何在我的Laravel 5应用程序中使用Illuminate \ Support \ Str :: slug?

来源:互联网 

I'm doing the following in the

我正在做以下几点

public function boot(DispatcherContract $events)
{
    parent::boot($events);

    // set Tag slug
    Tag::saving(function($tag)
    {
        //slugify name
        $tag->slug = Str::slug($tag->name);
    });
}
pu



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: