Share Facebook on iOS & Android [solved]

0 favourites
  • hi,

    thanks for quick reply

    i want that player share his score on his own facebook account and not to specific facebook page ? you understand me

    sorry for my bad english

  • matrixreal, as far as I understand, I think you need to have your game registered with facebook for the share to work. When you then share, you'll see that it goes directly to the player's page and that it is only directed through your registered game to enable this to happen. It's still not totally clear to me even now...

  • mmm ok i understand you

    but ... are you sure that this work with ejecta ?

    and you use browser plugin ? (because i just try it with browser plugin simple go to "http://facebook.com" for exemple and nothing happen , it not open facebook page)

  • matrixreal, for me - yes it works. It sounds like it could be a problem with your events but I can't really help without seeing them. I have never had any problem linking inside ejecta to open a default browser window on iOS (which doesn't directly help you, but it means that there is a solution!).

    Here's the string that I use to open up a new browser window. I have sub-events to replace the XX and ZZ with more string info depending on what the user has just done - ie the reason for the wall post. I have replaced my app id here with YY as well.

    https://www.facebook.com/dialog/feed?app_id=YY&link=ZZ&picture=https%3A%2F%2F24.media.tumblr.com%2F297f80fc891de7f6da2578fee2a97c9e%2Ftumblr_n3mqo7aWXo1txhoh7o1_r1_400.png&name=I%20was%20just%20in%20a%20meeting%20that%20cost%20DDXX!%20&caption=%20&description=Cost%20That%20Meeting%20-%20available%20on%20iOS%20%26%20Android.&redirect_uri=http%3A%2F%2Fwww.facebook.com%2F[/code:mus0yp6v]
    
    As you can see, the name and description parts have been encoded so that there are no spaces.  
    
    My final browser command is
    
     [code:mus0yp6v]Browser : go to FB_URL in a new window ("New Window")[/code:mus0yp6v] 
    
    where FB_URL is the final string for the URL.  If none of this works, can you post a screen shot of your event sheet?
  • ok

    about creating facebook id (game developper)

    i need just to create one to get an ID or i have to send it to be approved in facebook ?

    really it confuse m

  • It's a bit out of date, but the principles still apply. Read this facebook app tutorial - that should help.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • hi,

    now on twitter work fine ...

    but with facebook

    i just copy and past your posted url and change app id , link "with decoded and encoded" but still same on ios

    if i check it on construct (preview) it work ... but not in simulation on xcode and device (iphone4s"

    it give me "error try later"

    and what about this "Browser : go to FB_URL in a new window ("New Window")"

    where you change it ?

  • I use text replacement in pre-events to insert the specific info for the post. FB_URL is just my variable name for this.

  • Thank you for advice.It's work on android app but facebook brower show message error. How to fix this problem.

  • yes on ios it give eroor for facebook

    but if we check it on construct 2 previem its work

  • Sorry chaps - the only suggestion I can give you is to ask you to post your link code here and I or someone else can take a look at it. X out the bits you want to keep secret if you want....

  • i encode all the link except the first facebook link and now its work

    thanks a lot

  • matrixreal - excellent!

  • I use code : "https://www.facebook.com/dialog/feed?app_id=289001427926470&display=popup&caption= Check out my MyGame score of &link=https://developers.facebook.com/docs/dialogs/&redirect_uri=https://facebook.com&name=FlyingBunny&picture=https://31.media.tumblr.com/26fde50632cae49097f8b717160ae57f/tumblr_n5g8lejUS21tbc39ho1_500.jpg&description= Can you beat my score?"

    in url(str) : It's work in android device but when open in new window facebook page show message : "An error occurred.Please try later"

    This image in my c2.

    https://24.media.tumblr.com/4dd12702d3a2d41c30ed594c9b84f06b/tumblr_n5i1i0sT7t1tbc39ho1_1280.png

    Apologize for my English language,Please help me thank you very much.

  • aumthong99, this should be easy I hope! You need to encode the sections with spaces. Encode these bits:

    caption= Check out my MyGame score of

    (including the space at the end before the & symbol)

    description= Can you beat my score?"

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)