Add to homescreen on mobile

How can I code a button to create a shortcut for a mobile phone, especially on iPhone and Android.

I am using the template as a frame, so it automatically adds it to the head section <link rel="shortcut icon" href="img/l/apple-touch-icon.png">

. I think this will be my default icon to be used.

now i have a button in my html set up like this:

<a href="#"><img src="img/button-shortcut.jpg" /></a>

      

I'm not sure what to add to mine href

, or should I implement it with javascript. I'm also not sure what the correct term is, I'm just guessing it's called "shortcut"

What I am trying to achieve is I have a simple web application (simple html) and I have a button to add a shortcut / icon to their desktop. This way it is easier for them to access my website / web application. My target devices are iphone and Android.

Can someone enlighten me?

Thank!

enter image description here

+3


source to share


1 answer


You cannot create a shortcut for this function on iOS, and I am also not aware of this on Android. IOS users should use the Safari toolbar to add something to the home screen.

Some sites use JavaScript to present a small popup to the user, for example:



+1


source







All Articles