If links in test app work, but in main - don't, probably you have errors in main app. You have to check service settings and what data (links) crash in test app and in main app. (You can use alert function in mapping)
If links in test app work, but in main - don't, probably you have errors in main app. You have to check service settings and what data (links) crash in test app and in main app. (You can use alert function in mapping)
I have used alerts. The right links are in place, but the link events just don't get called. So far this is only in android, but when the device is rotated in the horizontal position, links work. That seems really odd and unrelated to me, but that's what happens.
On what device/version do you test? Can you make a try on the other device?
If you don't have the possibility, please share your app with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a and tell steps to reach, we'll test it.
I'm using a droid Razar. I'll send the info for the test account to a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a
I've also modified Katya's code so that it works for iOS and android. The problem with it is that android won't return an empty object.
code
function myNavigate(url) {
try
{
navigator.app.loadUrl(url, { openExternal:true } );
}
catch(err)
{
console.log(err);
}
try
{
var cb;
if (window.plugins)
{
cb = window.plugins.childBrowser;
}
if (cb != null)
{
cb.showWebPage(url);
}
}
catch(err)
{
console.log(err);
}
}
/code
navigator.app.loadUrl only works on iOS, so the try catch makes sure that cb.showWebPage opens.
Hello,
The problem is that your function returns nothing because you don't call return.
Please share your app with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a
Sorry, I should clarify, the window.plugins.childBrowser won't return an empty object on android. I do already have the app shared with appery.io. I've also already sent over the login information. The problem I am having is that android will only click on links (I'm talking about the ui object) if it is in the horizontal position. The above code works fine for most links (e.g. a href="http://" rel="nofollow"http:///a) but I haven't had a chance to test it with mailto: and maps and tel: links.
The above code works for iOS, I just need to test it on the android when I get back to the office.
Ok, the code I posted above works for android and iOS perfectly.
Thank you for the update! Please tell us if you have any problems.