This is a migrated thread and some comments may be shown as answers.

How to open http:// link outside app in any native OS browser -

2 Answers 318 Views
General Discussion
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Markus
Top achievements
Rank 2
Markus asked on 03 Dec 2013, 04:04 PM
I have an app that will display some links.

Now when clicked the links open in the app -> so there is no way back :-(

This is what I have tried without luck.

Any help on that? Using Icenium 1.9 with cordova 3. 

Homepage
                  <a href="javascript:window.open('#=Homepage#','_blank','location=yes');" target="_blank">#=Gemeinde#</a><br /><br /><br />
                  Homepage 2
                  <a href="#=Homepage#"    data-rel="external" >#=Gemeinde#</a><br /><br /><br />
                  Homepage 3
                  <a href="#=Homepage#"    data-rel="external" target="_blank" >#=Gemeinde#</a><br /><br /><br />
                  Homepage 4
                  <a href="#=Homepage#"    data-rel="external" target="_system" >#=Gemeinde#</a><br /><br /><br />
                  Homepage 5
                  <a href="#=Homepage#"   target="_system" >#=Gemeinde#</a><br /><br /><br />
                  Homepage 6
                  <a  onclick="window.open('#=Homepage#', '_system');"> #=Gemeinde#</a><br /><br />

Markus

2 Answers, 1 is accepted

Sort by
0
Accepted
Zdravko
Telerik team
answered on 04 Dec 2013, 04:22 PM
Hi Markus,

You can open an external link via InAppBrowser by setting the target value to '_blank'. Then when the link is opened a 'Done' button will appear in the browser which will return you back to the application.
Here is a link to the window.open command and the available target values.

I would recommend reviewing our sample-in-app-browser application for more information. If InAppBrowser does not work in your project, there could be some other javascript failing that would cause all js to fail. Isolating the issue in a sample is the best way to advise you accordingly.

Regards,
Zdravko
Telerik
You've missed the Icenium Visual Studio Integration keynote? It has been recorded and posted here.
Looking for tips & tricks directly from the Icenium team? Check out our blog!
Share feedback and vote for features on our Feedback Portal.
0
Markus
Top achievements
Rank 2
answered on 10 Dec 2013, 10:52 AM
Dear  Zdravko 

It seems after redeploying it works now. Strange I refreshed the app on Android many times pressing the menu button.

Well good thing it does now work.

Markus
Tags
General Discussion
Asked by
Markus
Top achievements
Rank 2
Answers by
Zdravko
Telerik team
Markus
Top achievements
Rank 2
Share this question
or