Sharekit - Facebook configuration
Asked Answered
P

3

6

I am trying to integrate sharekit in an ios app. Everything works properly but I have problem with Facebook. What I'have done so far :

  1. created an app on Facebook (no extra configuration on Facebook, like native etc..)
  2. edited SHKConfig.h and added
    #define SHKFacebookAppID @"MyFacebookAppID"

  3. in my app.plist added the url scheme : fb+appID
    Now When I try to share something on Facebook, the Facebook app on the device is opened, showing the message : You are logging into this app as "facebookUsername", when I click ok I'm redirected to my app but nothing happen, no sharing action.
    I am missing something??

Purgative answered 1/2, 2012 at 9:27 Comment(0)
P
3

The solution to my problem is illustrated here sharekit installation guide step 6

Purgative answered 8/2, 2012 at 3:48 Comment(3)
@Danish it's not. He can't receive bounty on his own answer ;)Alec
@Martin oh so who get the bountyThanatos
@Danish nobody. It will vanishAlec
H
1

Things You have to do for Integrate Sharekit With your Application..(Recommended)

1) Actually You dont need to set URL scheme in .plist file for Sharekit. It's only for facebook API users..

2) Check out,Did you fill api key and secret key in SHKConfig.h file like this below

#define SHKFacebookKey              @"YOUR_API_KEY"
#define SHKFacebookSecret           @"YOUR_APP_SECRET_KEY"

3) Verify Did you "import SHK.h" file..

4) You have to include "MessageUI,SystemConfiguration and Security frameworks".

5) You dont need to do this #define SHKFacebookAppID @"MyFacebookAppID"

6) Invoke sharekit actionsheet as given in documentation.

Homer answered 11/2, 2012 at 8:20 Comment(0)
P
0

The SHKConfig.h file seems to indicate that you don't include a literal "+" in your URL scheme. Check the last line of this quote:

// Facebook - https://developers.facebook.com/
// SHKFacebookAppID is the Application ID provided by Facebook
// SHKFacebookLocalAppID is used if you need to differentiate between several iOS apps running against a single Facebook app. Leave it blank unless you are sure of what you are doing. 
// The CFBundleURLSchemes in your App-Info.plist should be "fb" + the concatenation of these two IDs.
// Example: 
//    SHKFacebookAppID = 555
//    SHKFacebookLocalAppID = funk
// 
//    Your CFBundleURLSchemes entry: fb555funk
Propinquity answered 6/2, 2012 at 20:54 Comment(1)
Actually I do not include the + in my url scheme, anyway I managed to solve this.Purgative

© 2022 - 2024 — McMap. All rights reserved.