Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the best practice to create a unique url for every user profile

In my every application i want to create a unique url for users profile as http://app.com/username .

I have the name of user is : 'Vijay Kumbhar' i can create http://app.com/vijay_kumbhar, but if there is another user registers with the same name then what will be better way of creating url for that user. one way is to add vijay_kumbhar_1, but i dont think this is the proper way of creating a unique url

Can you please suggest me the better way of doing this.

like image 490
Vijay Kumbhar Avatar asked Jul 11 '12 11:07

Vijay Kumbhar


People also ask

What is a unique URL?

Essentially, a vanity or custom URL is a unique web address branded for marketing purposes. It is specific to your website and your business and can help your audience reach you more quickly and easily.

What is a user URL?

This custom URL typically serves as the Web address of your profile page and can be shared and bookmarked by other users. Examples of websites that allow you to choose a personal URL include social networking sites like Facebook, photo sharing sites like Flickr, and various Web forums.


1 Answers

Keeping in the User experience in consideration, firstly provide the user with unique id, through which you can identify the User easily. After that you can allow the User to opt for any new User Name (screen name), but there should be a check again that the user name has to be unique again. Depends upon your requirement. Do keep us posted what way you opted at last.

like image 146
Nishant Shrivastava Avatar answered Oct 11 '22 22:10

Nishant Shrivastava