Jump to content

Grabbing users image from facebook help


ukscotth

Recommended Posts

Hi,

 

Im creating a facebook app and I want to be able to grab the users full size profile picture and save it locally. Apparently you can do it with this code :

 

<script>
FB.api('/me/albums', function(response) {
        for (album in response.data) {
          if (response.data[album].name == "Profile Pictures") {
            FB.api(response.data[album].id + "/photos", function(response) {
              image = response.data[0].images[0].source;
		  

            });
          }
        }
      });
  </script>

 

Sorry if this is a stupid question but how would I echo out the image path after funning that ? Im only used to working with php.

 

Thanks,

 

Scott.

Link to comment
https://forums.phpfreaks.com/topic/250735-grabbing-users-image-from-facebook-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.