Results 1 to 2 of 2
-
April 10th, 2012, 03:52 PM #110Registered User
postsFacebook canvas app, using both the PHP and JavaScript SDK
Hello! I'm currently making a Facebook canvas app where users can fight their friends by sending a list of moves and once both players have submitted, they can watch the fight (it's like a more complicated rock, paper, scissors).
I have everything working so far on the php side:
authenticating the user
loading variables between php and flash
mysql database entries and selecting
All was looking well and the game is fully functional except for one thing, I can't integrate the javascript sdk into it because I lose the ability for flash to communicate (using POST) to the php file. I realize using the javascript sdk makes the app behave more client side instead of server side, and that's the wall I'm running in to.
I need the javascript code to send app updates (e.g. "Your friend has challenged you!") and friend requests to the app, which I don't believe you can do through the php code (or it's being depreciated in October so I wanted to be ahead on that).
Any help on using both php and javascript while maintaining the ability for flash to communicated with my server is greatly appreciated! Thanks!
-
April 10th, 2012, 04:20 PM #210Registered User
postsUpdate: I probably need to use ajax so that flash communicates with javascript on the page, which then sends the request to php which returns to javascript and back to flash...
Any examples you guys/gals may have would be appreciated, until then off to google I go
For anyone with this problem this: http://www.kirupa.com/html5/displayi...ta_in_html.htm is a good resource with just javascript, no flash object, but it's a great overview!

Reply With Quote


Bookmarks