Page 1 of 1
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Wed May 08, 2013 10:33 pm
by Nevada Opera
I've developed an app and when testing on iOS I found that opening a HTML5 Web App from the Home Screen (using the Add to Home Screen option from the browser) handles opening hyperlinks differently than from within the Safari Web browser.
Steps to reproduce:
Create a publish a HTML5 Mobile Web App with a hyperlink to an external Web site. Specify "Open in new window" on the link options.
Open the URL for site.
Click on the hyperlink - it will open in a new window. Switch back the Mobile Web App window.
Use the Share button and "Add to Home Screen"
Open the Mobile Web App from the Home Screen
Click on the hyperlink - the target page will open in the same window and the user will not be able to navigate back the Mobile Web App
Anyone have a solution to this problem?
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Wed May 08, 2013 11:18 pm
by Illya Stepanov
Hi - we will test and update.
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Thu May 09, 2013 2:46 am
by maxkatz
Illya will test this, but it's possible that when you launch the app via a shortcut, iOS treats it more like an app and opens all links within the same window.
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Sat May 11, 2013 3:09 am
by Illya Stepanov
I tested the above steps and in my case all links are opened in a Safari browser.
So you can always return back to a one page app by double clicking the home button.
One note I've made it using Hosting tab and publishing it on the Web.
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Sat May 11, 2013 5:08 pm
by Nevada Opera
In my hosted app published at: http://mobile.nevadaopera.org/Opera.html
the behavior is a I described in the steps above.
The links open in the same window. The only way to return to the app is push the home button and re-open the app from the home screen.
This is on iOS 6.
I'm going to try an hack around a JavaScript handler.
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Sat May 11, 2013 5:23 pm
by Nevada Opera
Just to clarify, I'm adding a "Open a URL" to the "Click" event on a component, ref screen shot.
Using the "Link" works as expected
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Sun May 12, 2013 4:27 am
by Illya Stepanov
I will test it more and update.
Hyperlinks in iOS Home Screen Apps open in same window
Posted: Sun May 12, 2013 8:43 pm
by Illya Stepanov
I can't reproduce your problem. All links are open in a new tab in Safari (with "Navigate to Link" and "Navigate to Link" + "Open in new window") - and by double clicking Home button I can return into the app.
Your public app is without a link that is shown on a screenshot, so I can't test it.
Just in case, if you are making some changes in the app and Saved them - goto Hosting tab and re-publish your app.