Open app facebook / twitter app from Cordova - angularjs

What I'm doing is a login with social networks, this works very well but I have a doubt. I leave pictures of what I do and what I'm getting to be a little more understanding. I am using js library OpenFB.js. With twitter even I can not do much but what matters to me most is that if you can do this.
This is what happens is my application :
This is what I would like to happen, to open the application installed.

If you are already logged into Facebook, you will not see the screen on the first image otherwise the screen will appear. Based on the images that you have posted, in order to see the screen on the second image, you have to be logged in. The second screen is the new login flow of Facebook where you can look at the permissions the app is requesting for and if you tap on the edit link, you can refuse certain permissions that your app is asking.
Note that once you grant these permissions, you may no longer see this screen until you remove the app from your Facebook settings.

Related

Can't redirect from facebook embedded browser to mobile default browser

I'm having issues openning link to my website that I share on facebook.
By default, any link users open from facebook mobile app are opened in the facebook embedded browser.
This browser causing issues to my app so I'm trying to redirect the users to their default mobile browser, but I don't know how.
I've tried many solutions, but none have worked, the closes one was trying to do:
window.location.href="mywebsiteurl", but this prompted message on facebook app that I'm trying to leaving the app, but after accepting would leave the page just idle.

Redirect user to permission settings in ReactJS

I'm building a ReactJS app that requires location, camera and flashlight permissions. The problem is that most (if not all) browsers only ask for permissions once. Once denied, it will never ask again.
In the Chrome browser on my PC I can manually enable permissions by clicking the corresponding icon in the URL bar:
However, in Android and iOS the app is supposed to run inside a mini webview without the URL. So I will need to redirect the user to the corresponding settings in the browser manually.
I've browsed through quite some solutions on SO but they all refer to the navigator permissions method which can only ask for permissions once.
How do I direct the user to the specific site settings in Android and iOS?

What is an ideal login workflow along with Facebook's OAuth2?

So today, I tried playing with Facebook's OAuth2 in my AngularJS application. I was able to make an activity work by clicking a Like button in my app. I'm also able to check if I'm logged in to Facebook using FB.getLoginStatus(). So my question is, if we currently have a login page, what is the ideal user experience when combining it with Facebook?
Do you display Facebook login page then goes back to your original login(this is what is happening on my application right now)
Do you display Facebook login page then once you've been logged in, bypass your original login page and allow the app to bring you directly to the main application. But how do I find out the facebook username that was used to log in?
any more ideas?

The Datastore Admin page is blank in my App Engine Control panel

The Datastore Admin page is blank in all my apps on appspot.com, I have followed the instructions to enable them, and receive no error message, just a blank page load.
Can anyone help?
If you are on Google Chrome and logged in via multiple gmail accounts, try to open up App Engine dashboard using an incognito window. That should solve it.
For future users with same blank page problem and Federated login you can also try the following.
Try to open the Datastore Admin page and if it's black then view the page source.
Your should see something like this (chrome - firefox - safari):
<iframe style="border:0px solid #ffffff"
frameborder="0"
src="https://ah-builtin-python-bundle-dot-latest-dot-app-id.appspot.com/_ah/datastore_admin/?app_id=s~app-id&adminconsolecustompage"
width="100%"
height="1024px">
<p>Your browser does not support iframes.</p>
</iframe>
The link you are looking for is the src:
https://ah-builtin-python-bundle-dot-latest-dot-app-id.appspot.com/_ah/datastore_admin/?app_id=s~app-id&adminconsolecustompage
Copy the link with the datastore admin login auth and open it in a new window.
That will ask you from OpenID(GOOGLE) to confirm that you want to grant access to Datastore admin to your email etc.
Allow and done ;-)
PS. This works once and you don't have to re do it again. Though you have to follow the same procedure for each of your apps that you have enabled Federated login
It might also be because you are using Federated Login. I had the same issues with blank screens and no error messages. For me, the Datastore Admin became available when I changed the Authentications Options back to Google Accounts API. Definitely not a permanent solution, but desperate times calls for desperate solutions.
Ref: How to enable datastore admin
Open your browser's dev tools and look for errors in the console. In Firefox, I received:
Invalid 'X-Frame-Options' header encountered when loading 'https://ah-builtin-python-bundle-dot-healthometry-hrd.appspot.com/_ah/datastore_admin/?app_id=s~healthometry-hrd&adminconsolecustompage': 'ALLOW-FROM https://appengine.google.com' is not a recognized directive. The header will be ignored.
Open the long link in a separate tab and go through the federated login process. The datastore admin will appear. Upon refreshing your appengine.google.com page the Datastore Admin should appear there as well.

Google App Engine oAuth Issue

I'm working on building an iPhone application and using Google AppEngine as the data storage. I also need to have the ability to use oAuth for my users, but I can't even get oAuth to work at this moment on AppEngine.
Successful Demo:
http://twitteroauth.appspot.com/
Code powering that demo:
http://github.com/tav/tweetapp/blob/master/standalone/twitter_oauth_handler.py
The problem is that when I run the script on my account with my Twitter application information, it goes through the process successfully, but nothing happens. It takes me to Twitter for the "allow or deny" page, but when I allow, it just reverts me back based on the callback URL without the page thinking I'm logged in.
Anyone have any ideas?
You mean the login page in twitter? If your question is about twitter not showing the login page then you are logged into twitter already. If your question is about twitter not showing allow or deny (authorization page) then you have already authorized the application. Twitter doesn't ask authorization question every time.

Resources