Screen orientation when opening links inside Facebook native app mobile browser - facebook

Is there anyway to avoid Facebook opening a link in its own web browser or to show it on landscape mode? I've noticed it has portrait orientation locked and my app needs to be run over landscape, but it seems to not allow you to rotate the device.
Thanks in advance!

2021 here, and Facebook iOS browser still doesn't rotate with the device.

Related

Facebook SDK for Unity FB.AppRequest does not respect screen orientation on iOS

Facebook SDK for Unity FB.AppRequest does not respect screen orientation on iOS
I've tried with version 6.0 and 6.1beta, and both have the same issue.
My app is landscape (allows for both landscape orientations), what's really strange is the dialog (FB.AppRequest) pops up in Upside Down Portrait orientation, and then, when you try to search for a friend, the keyboard overlays in landscape! a real mess...

Portrait vs Landscape Launch Images

An iPad app can support inclusion of launch images in both orientations; presumably, if your app supports auto-rotation, then this would suggest to me that if the user launches an app while the device is in Landscape mode, then the Landscape launch image is used.
But in all the apps I've built and released, this has never been the case. Never once has the Landscape launch image appeared, only the Portrait. After loading, the app will auto-rotate to whatever orientation the device is in, but at launch, it assumes you are in Portrait. Always.
Why?
I have seen many other apps in the store that behave this way, but then there are some seem to always automatically know immediately at first launch, from that first launch image, that you are in Landscape, if that's the case.
How is this done?
iPhone supports only portrait images (http://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/IconsImages/IconsImages.html#//apple_ref/doc/uid/TP40006556-CH14-SW5)
Apps that don't support portrait orientations, provide the same portrait oriented image. For example, Angry birds on iPhone has the same portrait oriented image but the guys painted rotated graphics on it.
As it would turn out, the issue was due to leaving out the supported orientations in the plist file for the app. You can add these manually or just select them in the Target page. More details here:
How to get a landscape launch image to actually appear when launched?

screen shots for app store submission

Do I have to submit both portrait and landscape screenshots?
Is it fine for my app to only support portrait mode?
Enough just a portrait screen shot - I submitted the app like that.
Yes, no worries about that :)
Best of all this document (perhaps you already saw it) tells about all of this.
Portrait mode only should be fine. I have app in app store that supports only portrait mode.
Your screenshots can be in any orientation you want. No specific requirement. Although I think now they have to be 640x960 for iPhone.
You can upload screenshots in what ever orientation you want, and yes its okay to only support portrait mode in your app.

How can I fix the webpage orientation to Portrait only for iPad and iPhone?

I have developed a web app/website for the iPad but I can not get it stay in a fixed portrait view only.
I do not want it to rotate and work in landscape mode, because of the way the app has been designed.
I've tried various configurations of the viewport settings but that still has not worked.
I'm not very good at JavaScript so a copy paste option would be best or something in CSS/HTML.
Thanks in advance.
Unfortunately, there is no way to explicitly "lock" the orientation of a web-app in Mobile Safari, as you can also see from the link that Alex posted above in the comment:
How do I lock the orientation to portrait mode in a iPhone Web Application?
However, you can have multiple CSS files for different screen orientations. There's a handy JavaScript snippet that you can copy-paste here:
http://www.catswhocode.com/blog/10-useful-code-snippets-to-develop-iphone-friendly-websites
This should at least allow you to design around the rotation without having to use JS but just CSS.

iPhone mobile Safari vs home screen link resize issue

I am trying to write a web app for Android and iPhone.
I have an issue when the device orientation changes. On the Android the orientationChanged event fires (from portrait to landscape) before the new horizontal dimensions are reported (reports portrait dimensions, with iPhone it fires AFTER (reports landscape dimensions...correct behavior).
So I fell back to the resize event. Another issue cropped up. Android works fine in browser. iPhone is works fine when the app is launched from the home screen. However in mobile safari, the resize event is never triggered when roating from landscape to portrait, since the browser just provides you the capability to scroll around the page horizontally.
I need a way to detect an orientation change event and get the new dimensions from DOM elements in order to resize other elements on the screen that will work for Android, mobile Safari and home screen web apps.
Thanks
Fell back to device detection, since there is no reliable way of doing this generically.