I'm looking for a way to let people connect with facebook when posting comments, and to use their facebook avatars as the avatar for the comments. How can this be done? Do I need to create a seperate user account for those people, or is their a way to simply store an avatar url for each comment that's posted?
1 Answer
Three simple steps to generate a Facebook Avatar:
- Create an extra field in your comment form for the user's facebook profile (see e.g. WP Engineer for a code example and how to)
- If the user filled out this field, get the facebook avatar (see this question)
- Replace the WP avatar with your facebook avatar if a fb profile url is set
All together in this Gist (PHP5.3 required!). Tested with WP3.5 and FireFox/Chrome
Hint: It is strongly advised to read the code comments. There are several informations how to configure the plugin e.g. in the functions.php.