Once you have created a Caspio App that uses Facebook registration you can automatically display the user’s current Facebook Profile photo using the Facebook ID saved to your authentication table.

Simply add the following code into a DataPage. Make sure that Advanced Options and Parameters are enabled.

<img src="https://graph.facebook.com/[@authfield:Facebook_ID]/picture">

Replace Facebook_ID with the appropriate field name that holds your users Facebook ID.

If you want to display the Facebook image only if the user has a Facebook ID saved you can use the following JavaScript:

<script>
if ("[@authfield:Facebook_ID]" != ""){
document.write("<img src='https://graph.facebook.com/[@authfield:Facebook_ID]/picture'>");
}
</script>

Again, replace Facebook_ID with the appropriate field name that holds your users Facebook ID.