合并Facebook个人资料照片

I develop an application on Facebook where I get all the friends profile photos of a person.

Then I would like to merge all those photos into one (a blank photo with fixed width and height).

For my application I use the Javascript Sdk. I think it's not possible to do it with javascript, so I think to use Ajax and to merge them with php.

A lot of applications do this (birthdays applications for instance).

Is there an other way to make it without using Ajax? And if I use Ajax, do I have to save my merged image on my server?

Thank you.

Is there an other way to make it without using Ajax?

Yes, instead of AJAX, you can use old fashioned form-posts.

And if I use Ajax, do I have to save my merged image on my server?

It's unclear from your requirements as to where the image should live after the other photos have been merged into it.

Yes even you can use the php for the direct image!

Use an Img tag with blank.png src and onClick on a button or some else event, just change the src of the image using java script i.e. http://xyz.com/genrateImage.php?w=200&h=200 and you will be done! :)

in genrateImage.php you can use facebook API and generate image with phpimage library

<img src="http://xyz.com/blank.png" width"200" height="200" />

<img src="http://xyz.com/genrateImage.php?w=200&h=200" width"200" height="200" />