Route::get('{level1?}/{level2?}/', function($level1, $level2 = null) {}); // Etc.Should work
Route::any('{request}', function($request)
{
//
})
->where('request', '[a-zA-Z0-9./-_]+');
Catch your url with regular expression. Something like that should work.
Yep, I answered this earlier with this thread:
http://laravel.io/forum/03-11-2014-how-to-make-urls-seo-friendly-with-nested-set-model
You can pretty much do the same thing you tried, but you need to chain a ->where() matcher, something like this:
->where('all', '(.*)?');
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community