PDA

View Full Version : Can you add an avatar to a login system


drunkmafia
07-02-2011, 10:09 AM
Hi ive just been wondering can you add an avatar to a login system so people can add it and one the members page it shows there avatar and in chat rooms?

Corrosive
07-02-2011, 11:28 AM
Hi ive just been wondering can you add an avatar to a login system so people can add it and one the members page it shows there avatar and in chat rooms?

Yes, of course but you'll need to program it.

Ricky55
07-02-2011, 02:49 PM
A very popular way to do this on blogs is to use the Gravitar system.

http://en.gravatar.com/

They have a plugin you can use. For users that don't have an Gravitar account you can specify a generic avatar.

Cheers

drunkmafia
07-02-2011, 05:15 PM
OK then if I can program it in, how can I allow users to upload an image into my mysql database and how can I make that specific image appear when you log in or re-enter the site?

Corrosive
07-03-2011, 09:55 AM
You will need to upload the image to a temp location and then store a path to that image in the database. When they log in the database spits out the image path and you'll then need to echo it out into an img tag in html based on which user is signed in. That's the theory anyway. Try this; http://webdevelopers.net/forum/showthread.php?t=101466