Create a Android launch icon for Website - android

I have a responsive website which can be accessed across multiple devices, our design and application is mainly targeted for mobile users.
To ease access to the site, we want to create a launch icon which will apear on the mobile home screen and user can access the site using one touch, as against launching the browser and typing the url / opening the bookmarked page.
I found a solution for it in IOS, which is also supported by the safari browser using which you can save the page url as a launch icon, can a similar feature be found on a android device? I would also be interested in prompting the users to create the launch icon if they are accessing it from a mobile phone /tablet.

Default Android
This is the preferred way since this is all based on default Android options and doesn't add any maintenance.
As a widget from bookmarks
If on android you long press the home screen and then select the widget option you can create a bookmark. This will let you select a bookmark from your chrome bookmarks to be linked on the desktop. If that works for you you're all set with default Android features. The icon from the bookmark is used on the desktop.
Directly from Chrome
Similar to this approach is selecting the "Add to homescreen" option in the chrome settings menu.
The icon is the icon from the website.
Custom alternative
As stated before the alternative is to create an app that only serves the purpose of being a link to your mobile website. Then you have 2 options:
Using default browser of user
An app that uses intents to open the default browser of the user with your URL. This should be the way to go since the user can now keep on using his favorite browser.
In app browser
An app that contains a single webview loading the URL of your webapp. This last option gives you more control over the browsing experience (blocking scripts, overriding requests, ...). However the user can no longer use his preferred browser.
About the icon
In both cases the Icon will be the icon configured and distributed within the app. This also introduce the need of a new app release if the icon or the URL should change.
About the code
Code examples and information about this webapp in app approach can be found at http://developer.android.com/guide/webapps/webview.html
Another good resource is https://developers.google.com/chrome/mobile/docs/webview/overview where mobile app development using a native android app with webview is covered with several aspects like tools, css tricks and more.

If I have understood your issue exactly then you would want to show a launcher icon for your website without creating any activity (screen) or doing any programming in android.
If this is the case then my answer is YES, as depicted in snap Google chrome provides this functionality to create a launcher/app icon on home screen.

Some webBrowsers like chrome enable the user to make a bookmark for a specific URL as an icon in the home screen, but I did not get evolved in a project like that. So it is possible.
You can make it simple by creating an application that contain only a webview to open your url and you can then create an icon for your app that hold the website on the home screen as the following in this answer

In my 3 years on Android I have never seen a website ask me to make a shortcut on my homescreen, however, the standard Android browser as well as Dolphin can create shortcuts from bookmarks.
While researching this with a quick search I found this thread states that Chrome allows this as well, and there's even a way to specify a homescreen icon for your users.

Related

My webapp as a shortcut won't open in a dedicated window on Chrome (Android)

The title may be confusing. Let me explain :
When you open a website in Chrome in Android you can create a shortcut to the page clicking the three dot icon in the top right corner, after choosing "add to Home Screen".
For some website/webapp the shortcut acts as a standalone app starter. In other words it opens in a dedicated container in Android and if you were to tap the shortcut again the app wouldn't open twice, instead it is aware a container already exist and send it to the front (only one instance).
It is as if Chrome recognizes the website as an app.
But for my webapp it doesn't work. If I make a shortcut on the home screen and tap it, the page opens in a new tab in the main Chrome instance. This webpage/webapp is supposed to be standalone, there is no point to have multiple instance of it in the browser. Ideally when I tap the shortcut Chrome should open the app in its dedicated app window (to avoid clogging the tab list uselessly.)
Does anyone know how to circumvent this problem? Are there some instructions to add in the HTML to force Chrome to recognize the page as an "app" and make use of its own container?
As I write this question I believe this has something to do with Progressive Web App, Chrome only accepts to "install" your website as an app shortcut if it follows a certain format.
But also my app doesn't need to implement all these progressive features, it's just a simple app that only myself is using.
So if you know how to force Chrome to produce this effect without writing a lot of code I would appreciate.
It does need to be a PWA. Here are the requirements.

Converting a WordPress site into a PWA

I have a WordPress website and I am transforming this website to a PWA with the help of a plugin.
The PWA is working as expected: notifications, working without internet …
I have also followed this tutorial completely:
https://css-tricks.com/how-to-get-a-progressive-web-app-into-the-google-play-store/
At the end, I have an Android launcher.
The new app is doing this:
If the browser is not set by default, it will ask the user to choose a browser.
I have an URL bar at the top of the app.
The app is not working without internet.
How can I fix all those points?
If the browser is not set by default, it will ask the user to choose a browser
Can't get this one, every mobile phone already do that by default, I think.
I have an URL bar on top of the app
Check if you have included the tag:
"display": "standalone"
on the manifest.json file
the app is not working without internet.
Check your service-worker.js file to see the resources needed to provide an offline experience are effectively cached. One can use this nice tool from Google to define routes policy easily.
You can use this Helpful tool.
Not installed yet
A URL bar being still visible at the top is indicative that the web page has not been installed yet as a PWA on your device. Choose Install from the tab menu or click on a [↓] icon next to the URL bar.
This will most probably also solve your other problems.

Android App Links settings, How to set App Link URL always open in this app?

Android introduced the App Links with Android 6.0 Marshmallow to provide a more secure way of launching a specific app from a (https) link.
Further, I thought Android App Links covers main vulnerabilities exposed by Custom Schemes.
One of the major vulnerability is that a malicious app waiting to intercept the same URL with a similar intent filter. And then the OS will show the Ambiguous Dialog to the user to select which app to open the link.
See: Measuring the Insecurity of Mobile Deep Links of Android
The App Link URL should take the user straight to the app if the App Link has been setup properly as per the documentation for the Android AppLinks.
However, I found that this may not always be the case. For some devices, the "Ambiguous Dialog" could be shown for the first usage of the App Link URL.
Why ?
There is this strange setting called "Go to supported URLs" under the App setting -> Set as default below App Links sub heading which App Link depend upon. This setting allows the user to change the App Link behaviour. It gives three options as below.
In this app
Always ask
In other app
The strangest thing is that the default for this setting will be different from each vendors devices.
If the setting is not "In this app" then the OS will show the Ambiguous Dialog with at least your own app and browser.
Question?
Is there a way of preventing the setting being changed (prevent URL being intercepted by any other app)?
Is there a way of setting the default to 'In this app' or change the setting programatically to 'In this app' to prevent being intercepted by other apps?

iPhone and Android: Create a launcher from mobile webpage

I'm developing a simple mobile webpage using pure HTML5 and CSS3 for my company. My boss has asked me to make in the webpage a way to create a launcher in the user's mobile phone home screen/launcher to the website, even if with the user's authorization (without the user needing to add the website to the favorites and then creating a widget to it, in Android's case). Is it even possible? I honestly believe not, as it could be a great security breach, but I want to ask to people with more knowledge.
You are right, for security reasons you cannot do this. On iOS as on Android, You will have to show a widget to the user begging him to add your app to his home screen.
On an iPhone you just tap the 'Add to Home Screen' button and the icon is added to the desktop, no drama, and no security breach.

Android App for mobile website

I'm looking to build an android app based off a mobile site. Basically, I just need an app with a browser that I can use as a platform.
Many of the "build an app online" sites offer this, where you just put in the home url etc, but they all include their own ads etc.
Any ideas where to start?
If you want to make your own simple app without Ads, use just a WebView inside of a simgle activity layout set to fill the screen.
Doing this you will eliminate all ads, as well as have the ability to add in more features later on if you so choose.
If you just want to create a launcher icon that will open up the default browser to your sites page, you can do that by just starting a browser intent, and then closing the actual app.
This will allow you to have an app icon and play store listing, however the only thing that iw will do is bring the user to your website like you have mentioned.
Create an Activity with a WebView.
I think you're looking for an app that displays a WebView. However, that will only display the website as if you were looking at it in a mobile browser such as Android Chrome.
If you want the data from a mobile site, without anything else, then you have to hope that the site provides that, or you have to download its HTML and scrape it.

Categories

Resources