I think that should be fine, as long as you make the email column in the database unique. You can also use "username", if you want.
Also consider, your users may not want their email address in a URL. That's where the username idea may be a little more appropriate.
Thank you. Now I need a email Route::pattern :)
Email pattern:
Route::pattern('email', '^[a-zA-Z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$');
Route::get('user/{email}', function($email)
{
// Only called if {email} is a valid email address
});
Email regex from http://stackoverflow.com/a/8829363/941158
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community