I have a standard facebook and twitter SLComposer that brings up a small saying and also attaches a link to the app on the message using the addURL: function. I'm testing it in iOS7 and whenever I brink up the composer I am immediately taken out of the app and to the attached link address (which in this case is the app store). It's only doing this in iOS7. 6 and under works just like before. Any Thoughts?
Try add image for share for preview of the url destination.
If SLComposeViewController doesn't have image for preview, it tries to get image from the URL of destination server.
In my project I've found redirection on server to AppStore from my server.
I'm seeing something similar, but only when adding URLs that redirect to the app store, such as bitly links. Regular links outside the App Store work just fine as do App Store links that are direct (e.g. do not redirect). Does this sound right? I think it's a bug in Apple's plumbing for catching loaded App Store URLs iOS wide...
The URL is fully loaded to generate the preview image that you see in the tweet/facebook. Reported as rdar://15228808.
The behavior of how the Social Framework works was changed in iOS 7. In iOS 6 my app would just show a dialog for posting to either Facebook or Twitter regardless of whether my device/simulator had an account setup with the respective service. In iOS 7 it will only show if I have an account setup. I think this is based on the method "isAvailableForServiceType:". Without seeing your code, I can't be sure this is your issue, but my guess is that it might be.
Related
Facebook graph API tells me I can get a profile picture of a user using
http://graph.facebook.com/100001225634061/picture?type=large
which works fine.
But If I used the same application in iOS devices this link is not working. For Hybrid applications, Graph url is not redirecting in iOS.
Any solution for this? Single solution should work on both the devices.
Thanks!
I had a similar problem recently where a Facebook profile picture wouldn't show up in my Ionic iOS app. I used a similar link you mentioned above.
Investigating the app in Safari showed an error saying:
The resource could not be loaded because the App Transport Security policy requires the use of a secure connection.
Turns out, for security reasons you have to use https instead of http in your links. Changing the link like that solved the issue for me.
I'd like to be able to send invitation in an email to a specific "event" happening inside my iOS app. So I figured I'd need to use custom URL. That's fine.
But I'd also like to be able to handle the user that doesn't have the app installed yet, to be taken to a mobile Safari and to the webpage with installation instructions for the app.
What would be the best way to do it?
I could try the following:
In the email I send a link to a http://www.example.com/joinevent/?id=foo
User is taken to a Safari webpage that sends a redirect to mycustomscheme://joinevent/?id=foo
If the user doesn't have the app installed this redirection won't work and he stays in the Safari - I could then handle the displaying of installation instructions probably.
But this approach doesn't seem "natural" for me. Is there a better/more native way to do it?
Try http://rdrct.it
It is a web service that allows you to achieve exactly this functionality very easily.
Full disclosure - I created rdrct.it
Here's the basics:
Login to the site, create a project for your particular app. Choose a unique code (this could be the name of your app).
You'll then be provided with a URL in the form: http://rdrct.it/uniqueCode
Once you've done that, you need to register the app's ID in the app store, and also details about the custom URL scheme. Tick "Auto-redirect" - what it will then do is try to open the app, and if that fails, it will automatically send the user to the app store.
If the app is opened, then the querystring is also passed to the app, so in your example case, the device will have been served: mycustomscheme://joinevent/?id=foo
It also works across multiple device types, so if you have the app available for Blackberry, Android or Windows Phone, then it will also do the same for those depending on which device type the user is using.
Like I said, I created it, but it should solve your problem.
If you are using Distimo to track you app analytics, they provide a shortlink to your apps that can be used also used to track conversions. It shows a custom page depending on the device used to access. This is especially convenient if you have the same app published in the AppStore, Google Play, Amazon, etc.
I have recently created a new Facebook app ID as I'm adding Facebook SSO integration into my app. My app within Facebook is set to Native iOS and I've included the Bundle ID and a current published app's Apple ID (for testing).
I've implemented the SDK as per the instructions (I have two other iOS apps currently using the SDK without issue as well). All delegate methods and required plist entries are in place for the URL callbacks.
After attempting a login I'm shown the Facebook white screen (just a loading spinner) with blue bar but after 5 seconds it redirects back to my app and hits the fbDidNotLogin delegate method. That method doesn't include any sort of retrievable error (at least none that is documented or available to me).
So at this point I'm at a loss for what might be causing my login to fail. Is there any way to get a more detailed error? Or has anybody else run into this same problem?
I had the same issue. Solved this by changing two items in the Facebook app settings:
Configured for iOS SSO set to enabled
Updated the iOS Bundle ID so that it matched by bundle ID exactly (previously the casing was different)
Not sure which item fixed it, I largely suspect the first...but worth checking both.
Make sure your device's time and date settings are correct. I had this happen to me when I recharged and turned on an iPod whose battery had died. The date and time were totally wrong, and when I set them to what they were supposed to be, I got the Facebook login dialog just fine.
I have an iPhone app using facebook connection using FBConnect from github code.
It worked fine in the simulator, however when I installed it in the device with existing facebook app from facebook it didn't work. It opens the existing facebook app instead of returning to my own app.
Checkout this link.
Better you can go with the approach given in the link as it works fine. I have myself tried this code and it has worked for me.
Also the sample project (with Facebook API implemented in it) is given in the below link which will be helpful for you to while implementing the facebook API as per the method given in the below link.
http://www.raywenderlich.com/1488/how-to-use-facebooks-new-graph-api-from-your-iphone-app
Also you can test the sample project on your device before going for this approach
Hope this helps you.
EDIT:
Have you registered a URL handler to respond to return requests from the Facebook app? on iOS 4 the Facebook SDK uses fast app switching which is designed to let the app handle most of the heavy lifting and let the users just hit "Accept" instead of having to re-enter login/passwords
In my iPhone application I have a UIWebview that shows an html page. Inside that page there are links that should lead the user to the iTunes application and the application they tapped on. However, when the user taps on the link it errors out with 'too many redirects'. Looking at it with a packet sniffer I see it just keeps redirecting to the same http://phobos.apple.com/... URL. I even tried changing the link scheme to 'itms://' but that results in a 'Cannot show URL' error. I could solve this problem by trapping the URLRequest and sending openURL: to the UIApplication but the app has already been deployed and I don't want to patch it. I rather do it on the html/js/server side if possible. Anyone have any ideas?
For anyone still searching for this answer, I found that it seems to be a problem on the simulator which doesn't support itms:// URLs (because there's no App Store app). I didn't see the same issue on hardware, where the App Store app opens just fine (in my case this was when testing URLs from AdMob adverts, but it's probably the same for UIWebView).