Hi, i m working on asp.net with c#. i have 4 users . 1. Admin 2. Employee 3. Student 4. Guest User 1,2,3 can login into my site. whenever particular admin or employee or student logins of any then it shld show there photo in there profile... so after login session.. i want show there own photo.. and registration are done by admin so at at that time student and employee photos are uploaded. so plz tell me what to do ? i have no idea abt it... if possilbe give me some code. thanks
Depending what level of security you want on the photos, simply name the photos as username.jpg and then when they're logged in you have their username and therefore can put the right image there
Usernames have to be a unique identifier, most also don't allow users to change their usernames but if you did you would need to ensure the filename is also changed at the same time. You would discard the original filename of the uploaded file as it risks duplication.