Ionic - After successful payment app redirects user to external browser - ionic-framework

I am using the Novalnet payment gateway and using it as an iframe on my ionic app. So when a user makes a payment the Novalent redirects user to Redirect URL, which must be also in an iframe, but now what's happening is it's redirecting the user to an external browser. and due to which app is not working fine as it must be.
Please help how to stop this to opening URL in an external browser.
We tried iframe and inAPP browser also.

Related

How to use Google OAuth 2 in facebook embedded browser

I have a new website that require users to log in with Google login (using react-oauth/google package).
The problem starts when users clicking on my website link from the facebook mobile app, and then they're redirected to the website in the facebook embedded browser.
However, since last year, Google login blocks embedded browsers.
Is there any way to either:
Configure something so people coming in from facebook could log in using google-login, without the need of redirecting them to a different mobile browser?
If not, how can I redirect the users out of facebook and into their mobile default browser? window.location.href="my.url" don't actually openning any browser in the mobile.

Capacitor Browser issue with Redirect

The Capacitor Browser is having issues with web redirects - with different behaviors in iOS and Android. I think this is a very buggy plugin, but maybe I'm missing something...
My Ionic app uses the Capacitor Browser plugin to present a Federation Login page. There is an "authentication URL" returned upon successful SSO login - or if the user is already logged in then there is an immediate "authentication URL" redirect.
Here's what I am seeing...
iOS: for a first time login, the web redirect works and deep links back into my app -- no problem here. However, if SSO is active, then there is an immediate redirect which the Browser ignores. I can see the URL change, and it works if I open it in a separate mobile web browser.
Android: for a first time login, the web redirect is ignored and the user is left stuck in the browser. Again, if I copy the URL to a separate web browser then it deep links back into the app.
Has anyone done this successfully or have any workarounds? I've tried the "Cordova" and "Awesome" InAppBrowser versions of this plugin, and they don't redirect at all (although they have a bit more control over closing the browser, etc.).
I encountered a problem like this on Android lately,
The in app redirection was down on Android 12, users where locked on a white screen where we normally get the token in the url and redirect in app.
In my case it was related to this :
https://developer.android.com/training/app-links/verify-site-associations?authuser=2
The chrome browser was trying to check this file to verify the hash of the app to perform the redirection but it was unavailable due to internal network configuration, so it was locked.
This check seems to append on Android 12 only, and needed a re-install of the app on users devices (cache on in app browser ?).
Hope this can help.
(Ionic 6 Capacitor)

App on Facebook mobile gives me 4oh4 / 404

we have created a Facebook app, but when opening this on a mobile (via Web or iPhone) the page results in a 4oh4 error. I have setup a Mobile Web URL but still (after 1 hour wait) gives a 404.
Do I need to make specific changes on my app?
Please help.
This is expected as #Igy stated. You will need to have a handler to support redirecting mobile users to your apps.facebook.com/ or you can redirect them out of Facebook to your own URL if you are going to try and link to your page directly with an app embedded as a tab.
i.e. point link to http://yoursite.com/redirector
is mobile goes to http://yoursite.com/myapp or http://apps.facebook.com/
non mobile goes to http://facebook.com//app_
Some things to note:
You won't get any page specific data back from facebook on your page (i.e. Liked or Not Liked).
Based on #1 you won't be able to restrict the non-liking app users from a page.
After trying everything under the sun to get Facebook to redirect to a mobile web URL, here is what I needed to do in order to get the redirection working:
Make sure the Facebook application is a canvas application. This gives you the ability to give the application a namespace.
Give your application a namespace so that you can access it through https://apps.facebook.com/NAMESPACE. From here, Facebook will do the detection for you, and if needed, redirect your users to your specified mobile URL.
Make sure your app is NOT in sandbox mode.
If your app is in Sandbox Mode, Facebook won't redirect you to the mobile version you have specified in your app settings.
Facebook does the redirecting for you, you don't have to. Although their version of what "mobile" is and what you deem "mobile" might be different.

Cannot see authorize dialog when user wants to install my app

i have created an facebook application
when trying to access the application for the first time
i don't see the dialog asking to authorize the application
i only see a facebook logo ,
only when pressing the link under the logo i can see the auth dialog
what i am doing is to redirect the client to this URL
https://www.facebook.com/dialog/oauth?client_id=my client number&redirect_uri=http%3A%2F%2Fmy-side-domain.com%3A9000%2F&scope=read_stream,user_birthday,user_location
can u tell me what i am missing
(it redirect ok under chrome , but not on firefox)
thank you
Is this a canvas app on facebook.com? What you are describing sound like what happens when you do a redirect to the oauth dialog in a canvas app within the canvas iframe. You need to bust out of the iframe during the redirect:
Because of the way that we currently load iframes for Apps on
Facebook.com, it is important that you navigate the top window of the
user's browser to the OAuth Dialog. Many apps do this by sending a
script fragment to the user's browser setting the top.location.href
property to the dialog URL.
source: http://developers.facebook.com/docs/appsonfacebook/tutorial/#auth

How to become redirected to Facebook's Mobile Web URL

I would like to integrate an existing, external application with Facebook using Mobile Web method and its authenticated referrals as well as to be able to redirect user (incoming from a different place) to Facebook login page. I do not want it to be embedded in Facebook page.
If I understand correctly how the authenticated referrals work, I must somehow reach the authentication dialog which will redirect me to the Mobile Web URL, which I specified in the application configuration.
Additional information: I would like to avoid making the application public until it is ready, so I have set the Sandbox Mode setting to Enabled.
How to get the URL, with which I will be able to test authenticated referrals?
You can land at your game's Mobile Web URL page using following steps:
Switch your user agent to iPhone or other mobile.
Go to the http://m.facebook.com page.
Press the "identity" icon in the top left edge of the screen to show the bookmarks menu.
Look for the application in the Apps section.
Press the application bookmark.
Above procedure worked for me. My user was an admin of the project but it will probably work also for devs and testers (just a guess).