Streaming live at 10am (PST)

How to use Dynamic Facebook profile picture as a CMS field

#1

I’m creating a staff page and I want to use the facebook profile pictures for each person and have them dynamically update whenever they change their profile picture. I found a doc that shows I can use this: http://graph.facebook.com/userid/picture?type=square but not sure how to embed that properly. I also found a jQuery example of:
( document ).ready(function() { console.log( “ready!” ); var photo_link = ("#photo_link_text").text();
$("#image").attr(“src”,photo_link);
});
but I’m not sure how to make that happen or if there’s a different way. Thanks in advance.

#2

Can you explain a little bit more of what you’re trying to achieve here? Details of the project will help a lot and if you can share your read only link that would help us to understand better.

#3

Hi, thanks for the reply. I don’t have a link but I’ll do my best to explain what I’m wanting to do. I want to create a staff directory page using CMS with a picture of the staff person and a short bio. Id like the staff pictures to source their image from the corresponding Facebook profile pic of each staff member. This way whenever a staff person changes their Facebook profile picture the image on the website would update also. Does this make sense? Thanks in advance.

#4

First you would need to establish that there is a way on Facebook to externally access a profile users picture without being logged in to facebook, and if they support embedding it on websites. If you used the facebook API (with an accesstoken) you can access the picture.

How to do that is available at the Facebook Developers Website.