I read the FBCOnnect example code for iPhone downloaded from http://developers.facebook.com/docs/guides/mobile/ But it opens the facebook page on safari or on the device, the open application is open and the application switches in the background. I do not want this to happen. Also, the callback method '- (void) fbDidLogin' is not called at all after logging in.
In the Facebook iOS SDK, you can edit the Facebook.mm authorization method and set safariAuth and authorizeWithFBAppAuth for nothing, and to log in to Facebook.