How do I open a link in Google chrome in Lua? - lua

The actual question. You can open the app via startApp, but how do I set an activity with a link?
startApp('com.android.chrome https://stackoverflow.com/')

Related

How iOS URL Scheme work with a https website

I was developing an iOS application which need to work with a website. I'm not the owner of website so I cant use the universal link. I tried to open the website url https://example.com/xxx/xxx directly when I set the https://example.com/xxx/xxx as URL Scheme , however it will only display the website but won't asked for open the apps. What is the problem and can I do to achieve the expectation below?
Expectation:
When the user open the website
Phone w/ app - open the website and ask for open the app
Phone w/o app - open the website
I have similar problem with this question.
iOS URL scheme or not existing Universal Link
If you don't own the website you want to deep link to, you can't dictate the behavior once the user lands on that destination in their browser – that would need to be handled by that website.

Short URL not opened in App with Universal Links

I have set up Universal links in my iOS app, and it works with full URL like : example.com/path/
Recently, I want short URL like: t.cn/m , which map to example.com/path/ , can be opened in my App directly. So I added appplinks:t.cn at association domain in Capabilities.
But it doesn't work. It can't be opened directly in my App.It's opened with safari and i have to click the "open" button on pull-down-banner in safari to open in my App.
It seems like short URL can't be opened directly in my App, can it?
try applink instead of appplinks
from documentation

Open RSS file in chrome then it ask for download

I am working on Rails application where i created RSS feeds.
When i open link into Firefox it open good but in chrome it ask for download file or nothing.
What actually issue here or give me proper way to create and display RSS link if any buddy have a experience in it.
Thanks
This might be because, Your Google chrome does not have built in rss reader, to make google chrome lighter.
More information here.
To get rid of this problem you can add rss reader in google chrome by adding it from chrome webstore.
Follow below steps :
In your Chrome browser open
https://chrome.google.com/webstore/search/rss?hl=en-US
Enter 'RSS Feed Reader' in the search box (top left)
Press your 'Enter' key
In the results click the '+ Add to Chrome' button next to 'RSS Feed Reader'

Open iOS App by http:// link

I found a lot of tutorials about opening an app by a custom url scheme like:
myappname://
Thats nice but it would be great to open an app by registering the real app domain over the http link like
http://www.myappdomain.com/blablabla
So - for example - if a visitor comes to a webpage (on her/his mobile) it is normally opened in the browser, excepts the installed app is listening to the opened URL and opens itself instead of the browser.
How is this done (i've seen this at another app). Any help would be great. Thanks in advance!
It is a new feature in iOS9. It is explained in the WWDC15 talk Seamless linking to your App.
You could also add a small piece of javascript to each page that opens your custom URL-scheme.

Phonegap : cannot open iOS 6 native maps application

I've got an issue with an app builded on phonegap build (build.phonegap.com) on iOS with Phonegap 2.3.
I'm trying to open the native map application with this link :
<a id="gmap_image" href="">
</a>
The js code that sets the href attribute :
$("#gmap_image").href('http://maps.apple.com/?q='+$xml.find( "adresse" ).text());
I've seen that for opening native maps application with a link, i have to give an url based on maps.apple.com domain (Apple Map Links).
But when I click on the link, all that happens is that the page refreshes (and I don't know why it refreshes too because no code asks to do it).
Has someone an idea ?
Regards,
maybe it's too late, but i had the same issue.
Try this way:
$("#gmap_image").href('maps:q='+$xml.find( "adresse" ).text());
just change http://maps.apple.com/?q= into maps:q=
that works for me
You can launch the google Maps app on an iOS device using this header in the URL Scheme. comgooglemaps:// This is according to the developer documentation found here. https://developers.google.com/maps/documentation/ios/urlscheme
for example a web link to open the Google Maps app in iOS6 and get directions from New York to Washington DC would look like this.
Directions from New York, NY to Washington DC
Try this one
$('#map').bind('tap', function(){
var url = 'http://maps.google.com/maps?';
url += 'q=[place_name]'; //add ur querystrings
// open the native maps app by calling window location
window.location = url;
});
Unfortunately, this is a no-go on iOS 6, since Google maps is no longer "natively" part of the OS.
Though you can still launch Apple Maps, since this is supported natively.
If you are using one of the latest PhoneGap/Cordova versions, it seems that it's not longer possible to open safari or maps from standard "a href=xxx" tags.
In order to open maps, you will need to attach a click event and open the link using:
window.open('http://maps.apple.com/?q=whavever', '_system');
within Phonegap, window.open() will open a link with a new in app browser, but, if you specify '_system' as the second param, it will send the URL to the OS (thus, opening the maps app in this situation).

Resources