阅读(2897) (9)

Laravel 8 Str::start()

2021-07-03 16:54:20 更新

Str::start 方法是将给定的值添加到字符串的开始位置,例如:

use Illuminate\Support\Str;

$adjusted = Str::start('this/string', '/');

// /this/string

$adjusted = Str::start('/this/string', '/');

// /this/string