Build 10 games and learn game development along the way in this fast paced game development course

Get the source code of 12 commercial games, loaded 50+ million times, and learn the secrets of game design

Learn how to make a successful Flash game from a real world example. Fully commented source code

Create realistic Flash physics games from scratch with advanced features, from Angry Birds to Crush the Castle

Horror Profile Facebook application source code released

Horror Profile is a Facebook application I developed a month ago.

Now it’s time to release the source code. You will find some useful tips about dynamic image creation with php.

If you are absolutely new to Facebook applications, I suggest you to read “Developing a Facebook Application for absolute beginners” posts 1, 2, 3, 4 and 5.

The idea is simple: placing the profile picture in a mirror (that is a transparent PNG image) and writing the user first name as big as I can.

Hope you will make something decent out of it…

Rate this post: 1 Star2 Stars3 Stars4 Stars5 Stars (10 votes, average: 3.90 out of 5)
Loading ... Loading ...
Learn how to make a successful commercial Flash game from a real world example: get the fully commented source code of Globez, a Flash game played millions of times which generated a four figure income. Limited copies available.

Get it now
Be my fan on Facebook and follow me on Twitter! Exclusive content for my Facebook fans and Twitter followers

This post has 24 comments

  1. Sergey

    on December 5, 2009 at 6:34 pm

    Emanuele, do you know how make your flash applications running inline on Facebook?

  2. arxanas

    on December 5, 2009 at 7:16 pm

    I’ve been wondering how PHP image creation worked…

  3. Emanuele Feronato

    on December 6, 2009 at 3:03 pm

    you can do some decent image manipulation using GD libraries

  4. Cris

    on December 11, 2009 at 1:00 am

    I am trying to do something similar, but i think that i have to config my php server, but i don´t know how.

    I have this error in Facebook:

    PHP Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]: URL file-access is disabled in the server configuration in E:…\index.php on line 6 PHP Warning: imagecreatefromjpeg(http://profile.ak.fbcdn.net/v22941/664/25/q878789797987978.jpg) [function.imagecreatefromjpeg]: failed to open stream: no suitable wrapper could be found in E:…\index.php on line 6 PHP Warning: getimagesize() [function.getimagesize]: URL file-access is disabled in the server configuration in E:\…\index.php on line 8 PHP Warning: getimagesize(http://profile.ak.fbcdn.net/v22941/664/25/q……978.jpg) [function.getimagesize]: failed to open stream: no suitable wrapper could be found in E:\…\index.php on line 8 PHP Warning: imagecopyresampled(): supplied argument is not a valid Image resource in E:\…\index.php on line 18 PHP Warning: imagejpeg() [function.imagejpeg]: Unable to open ‘temp/100000378738508.jpg’ for writing: Permission denied in E:\…\index.php on line 42 PHP Warning: imagedestroy(): supplied argument is not a valid Image resource in E:\…\index.php on line 45

  5. David Salo

    on December 12, 2009 at 3:19 am

    Do you know to suggest invites once the my image is published?.I mean one thing that some apps do, when you publish the thing they bring you to alist of friends and you chose many of them to invite.

  6. Ze Ferreira

    on December 14, 2009 at 3:40 am

    here it is my 1st FB app inspired in your Horror Profile application.

    Be free to feedback it.

    http://apps.facebook.com/xmasprofilepic/

  7. Popoy

    on December 16, 2009 at 2:57 pm

    Hi Ze Ferreira,

    Nice app! it is possible to see the source code for it? :-) especially embedding of Google Adsense code.

  8. Ze Ferreira

    on December 16, 2009 at 8:21 pm

    Hi Popoy,

    to embedding adsense is simple and you have it her in the code of horror profile line 125 is one iframe and in the ad.html is the code of the adsense, easy. all the code is similar to horror profile with some variations.

  9. Malshan Fonseka

    on June 6, 2010 at 10:16 pm

    how to change the MIRROR.PNG

  10. Malshan Fonseka

    on June 9, 2010 at 10:22 pm

    but PUBLISH is NOT WORKING how to fix it

  11. Eric

    on June 19, 2010 at 8:33 pm

    Hi,
    Could u possibly create a flash tutorial almost similar to Horror Profile??
    The problem i faced is tat i do not know how to show facebook profile image and name in Flash.
    The method i using is FBML, PHP and AS3.
    THankalot if u have the time to create the tutorial.

  12. JaJa

    on July 18, 2010 at 11:01 am

    PUBLISH is NOT WORKING how to fix it

  13. Jack

    on August 22, 2010 at 5:54 am

    Fatal error: Call to undefined method Facebook::require_login() in /home/a5358356/public_html/horrorprofile/index.php on line 87

    How to solve?

  14. marciorosa.org » Horror Profile Facebook application source code released - Complete listing Tools and resorces for the ultimate web developer

    on September 9, 2010 at 4:34 am

    […] in a mirror (that is a transparent PNG image) and writing the user first name as big as I can.  Read more by Emanuele […]

  15. Christian Scholz-Flöter

    on October 1, 2010 at 1:14 pm

    Is it still sound advice to suggest reading the “Developing a Facebook Application for absolute beginners” posts?

    I am afraid that I am very suspicious because several attempts to get the simplest thing done in my own FB app have failed so far. I mean, you would delete the article when it becomes invalid, right? Or add a comment that what you are writing about is not valid any longer?

    My impression is that several developers have shared their Facebook related findings time and time again in the last three years. But trying them today has not worked for me in even one instance. Maybe it is because the articles contents I have read were true at the point of writing, but are showing techniques which today are invalid…

    Thanks for sharing!

  16. renan

    on October 6, 2010 at 12:19 am

    dont work for me all times tell me errors…..

    please post correct code

  17. mike

    on October 6, 2010 at 3:28 am

    It is great app but I’m geting error:
    Fatal error: Call to undefined method Facebook::require_login() in /public_html/horrorprofile/index.php on line 87
    Can someone help me with this?
    Thanks,
    Mike

  18. mike

    on October 15, 2010 at 8:30 am

    I’m interested in buying a working version of this script. Please contact me. Thanks.

  19. mike

    on October 15, 2010 at 8:32 am

    If you would like to sell your script/code (xmasprofilepic) please contact me. Thanks.

  20. Danny

    on January 19, 2011 at 3:09 pm

    I have wondered how images were created server-side since the beginning of time, great tutorial.

  21. Vivek Creations

    on January 14, 2012 at 8:26 pm

    Check my blog for more about application making of facebook.
    Your source code have error :)

  22. Mohsin

    on March 14, 2012 at 3:30 pm

    Parse error: syntax error, unexpected T_DNUMBER, expecting T_VARIABLE or ‘$’ in /home/mohsinhayat/app/www/index.php on line 80
    all the time i write facebook.php .. it fails.. whats the problem

  23. pawan

    on July 11, 2012 at 6:03 pm

    check out this one its updated
    http://www.techgigs.in/how-to-make-facebook-app-part-2

  24. ramansai

    on July 26, 2012 at 6:55 am

    i am new to fb plz tell me thet
    imagejpeg($im,”temp/”.$id.”.jpg”,80);
    does this line save the file in server

Thank you for the download!!

I hope you will find it useful and make something interesting out of it

To keep up to date with the blog, why don't you like my Facebook page and follow me on Twitter?

Want to learn more? Don't miss this:

Learn how to make a successful commercial Flash game from a real world example: get the fully commented source code of Globez, a Flash game played millions of times which generated a four figure income. Limited copies available.

Get it now

×