I have developed a windows app using jQuery Mobile and Phonegap. The app works fine in windows phone. But when I submitted it in windows store, the certification failed due to the failure in app certification requirements for windows phone 5.2.4.2 http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh184840(v=vs.105).aspx. It says that when they press the back button of the device from the home screen, the app is not closed rather it moves to the login screen.
My first screen is login screen. After logged in, the home screen is shown. If I press the back button of the device, the login page is shown again. But windows phone needs to close the app from the home rather moving to login screen.
There is no phonegap API available to close a windows application so I can't manage it in the javascript.
There is an exitApp() function available for android and it works fine. But it won't work with windows phone
I can't submit the app again and publish it until I fix the issue with back button.
Anyone faced a problem like this?
If so, Please help
Thanks
Have you tried this?
navigator.app.exitApp() is not working
Not sure if you finally resolved this issue. I had a similar problem which i fixed in index.js by
removing the event listener attached to the 'backbutton' event. Like this:
if (page == loginScreen)
document.removeEventListener("backbutton", yourMethod, false);
else
document.addEventListener("backbutton", yourMethod, false);
removeEventListener will allow the default PhoneGap backbutton press to exit the app.
Related
I am trying to implement the FB comments plugin (https://developers.facebook.com/docs/plugins/comments/) on a website. It's loading fine, but on iOS Safari the user cannot click into the comments field. When trying to click into the field, a quick visual glitch happens, and then focus is lost.
On some phones, if I log into facebook in the same browser, this makes an alert appear, when clicking into the field, to allow facebook tracking. After accepting that I'm allowed to click into the field.
I haven't managed to find any info on this. It's working fine on desktop/laptop macs and PCs, android and in iOS Chrome. But specifically in iOS Safari (on some phones) it's bugging out.
Does anyone know anything about this bug and how to fix it?
It's the settings -> safari -> Hide IP Address (from trackers) switch that stops the FB plugins working!
My App is in production now, and within my app I create a Universal link using branch.io and share it to other users using for example iMessage. Example link below I got from my friend is below:
I have the app from App Store installed on both devices: iPad and iPhone. Now the above link I tap on iPad and everything is fine. My App is opened I can catch the link:)
But when I tap it on iPhone the result is following:
Why? Shouldnt it works the same way on both: iPad and iPhone? I do not know what is wrong here... Any questions? I can change and add additional info here to help the solve the problem.
This is how I defined it in dashboard of branch.io:
You are encountering a new behavior introduced with iOS 10.3. The pop-up you are seeing will open the app now only if the user responds to the pop-up alert affirmatively. You must have not yet updated your iPad.
There is an unexpected issue with this new behavior beyond the obvious:
if the user taps "Cancel" on the pop-up alert, he or she will be stuck on a blank page in Safari. To improve this experience I recommend setting the $ios_passive_deepview parameter to the key of a Deepview of your choice (branch_default is the default, I believe).
I am trying to build deep linking feature into my app. I did all the necessary set up for deep linking to work like, enabling associated domains in my app, adding apple-app-site-association to the root directory of my server, and I am serving a valid apple-app-site-association over https, I also validated my apple-app-site-association using this tool Validate your apple-app-site-association.
After doing everything right, I tested the deep linking feature on my iPad and it worked as expected. But when I tried to do the same on my iPhone it doesn't work, it always took me to safari. I tried it on 6s device, I reinstalled the app, I cleared Safari website data & cleared the history. Also updated the iPhone & iPad to iOS 9.3.5. The updating the OS didn't change a thing.
iPad still continue to work with deeplink URLs just like it did while it was on 9.3.4. iPhone still opened the link in safari.
Please give me some pointers on how to workaround this issue, I think this might be an apple bug but again I don't understand how it can work on iPad which is running same software as iPhone. Any help or guidelines is much appreciated.
Thanks.
I was able to fix this issue and this is one of the annoying issue that I have come across, because it doesn't say what is going wrong.
Fix: Whenever the iOS opens your link in safari, you need to pull down the webpage in safari and there you'll see a banner saying that, open it in the app. Once you click on that banner your future links will start opening the app instead of opening it in the safari browser.
There was no error whatsoever and there was no indication why the link was getting opened I am pretty sure that, iOS didn't download the apple-app-site-association whenever I installed the app.
Also note that the banner in the webpage will not be visible whenever your link opens up in safari, you need to pull down the webpage and then the banner will become visible and if you click on open in app banner, it will start opening the links in app.
If in future if you select to view the link in safari by clicking on context menu which appears on right hand side of the status bar, which will be saying "Open in [your app name]" in safari, the links in future will open in safari instead of app, and again if the banner open in app isn't visible, you have to pull down the webpage to see that banner.
HTH.
In iOS 13, similar problem of direct links not opening the app instead it open the safari website directly.
Fixed by updated the below safari setting...
Settings > Safari > Request Desktop Website > All websites > Switch Off
I was facing the same issue in iOS 12, on one device the link redirected to my app and on another device it was always redirecting to Safari and pressing the link on the Notes app was only allowing me to open it on Safari.
What I believe happened was that I pasted the URL in the browser and clicked Go, as I thought it would redirect to my app. No matter what I did ( reinstalling the app, restarting the device, ... ) the results were always the same, redirecting to Safari.
What helped me was deleting the cached data for my domain ( Settings -> Safari -> Advanced -> Website Data -> Swipe and delete the data for your domain ).
After that, everything started working.
I believe this is a bug with iOS Simulator,
In my case it was occurred when I entered an invalid address (with multiple spaces) for example:
Valid One: myApp://order/10003101
Invalid One: myApp://order/1003131
It stopped working even with Valid One and the solution was to clear Safari Website Data:
Go to Settings/Safari -> Clear History and Webstie Data
Device: iPhone 12 Pro Max
iOS: 14.5
Xcode: 12.5
I had Universal Links working on my iOS 9 app. If I clicked on a UL from an email or text message, it would launch my app as expected.
Then I added a QR Code Reader and used openURL() open the UL embedded in the QR Code from within my app (which was supposed to be handled by the app itself).
On one test run, the URL embedded in the QR code was malformed: it had a CR/LF at the end of it, and when the app tried to open it, it crashed (I do not have the crash log/trace unfortunately).
As I researched the crash I realized that openURL() is not designed to work with UL, so I fixed the code to have my app handle the URL differently, but now none of the ULs work with my app anymore: what used to work from an email or text message doesn't anymore (it launches Safari instead of my app).
I install my app via TestFlight and I can see from my backend that the apple-app-site-association file is being pulled, but it still won't work.
Important data (that's how I know the problem is with the state on that specific phone): the same app on a different phone opens ULs correctly.
It's as if the one bug I ran into put the phone in a state that will always launch Safari for those URLs no matter what.
It is the only phone that exhibits this problem.
What I tried without success:
uninstalling the app completely
reboot
Not sure what to try next. Thanks in advance for the help.
You probably clicked on the link in the top right corner of the status bar to open one of your ULs in Safari. After that all subsequent ULs will open in Safari.
In Safari, pull down the page until you see the Smart-App-Banner at the top. Then click on 'Open' and ULs should work again.
I want to redirect the user of our iOS App to our Twitter profile page with the URL scheme:
twitter://user?screen_name=SCREEN_NAME
I recently noticed that this opens the Twitter app as expected but it shows a screen as if I used it for the first time:
The app is also completely frozen, I can't touch anything. If I keep the app open and klick on the UIButton in our app again, the profile will be shown correctly but still without being able to touch anything.
The only way I can get this to work is if I start the Twitter app before and let it open (in background). If I select the UIButton in our app now, everything works fine, the profile is shown and I'm able to interact with the Twitter app.
I think that there might be a problem of the Twitter app to handle such URL schemes on app start, but works when the app is already running.
Does anyone else experience this problem or have a solution for this issue?
Weirdly deleting and reinstalling the Twitter app fixed this problem. Still don't know why it happened though...