URL:
http://localhost/author-多米尼克•奥布莱恩.html
路由:
Route::rule('/author-:name', 'index/index/author');
获取的参数为:
^ array:1 [▼
"name" => "多米尼克"
]
求助,如何获取完整的“多米尼克•奥布莱恩”
http://localhost/author-多米尼克•奥布莱恩.html
Route::rule('/author-:name', 'index/index/author');
^ array:1 [▼
"name" => "多米尼克"
]
求助,如何获取完整的“多米尼克•奥布莱恩”
1 回答4.1k 阅读✓ 已解决
3 回答1.8k 阅读✓ 已解决
2 回答2.2k 阅读✓ 已解决
1 回答1.4k 阅读✓ 已解决
2 回答2.2k 阅读
1 回答592 阅读✓ 已解决
792 阅读
Route::rule('/author-:name', 'index/index/author')->pattern(['name' => '[\w\-\•]+']);
已参与了 SegmentFault 思否社区 10 周年「问答」打卡 ,欢迎正在阅读的你也加入。