ElkArte Community

Project Support => General ElkArte discussions => Topic started by: DeadMan on March 14, 2023, 02:48:01 pm

Title: Chrome shortcut
Post by: DeadMan on March 14, 2023, 02:48:01 pm
I've noticed that with ElkArte, when creating a shortcut with Chrome app (Android) the shortcut opens in own window and not in the browser.

I'd like to know what coding in ElkArte causes this, as I'd like to see if can use it on regular sites.
Title: Re: Chrome shortcut
Post by: Spuds on March 14, 2023, 05:52:23 pm
I don't think that was something Elk did  :undecided:  I'll have to try it myself !
Title: Re: Chrome shortcut
Post by: DeadMan on March 14, 2023, 05:56:36 pm
Found what it is.

Make site a PWA

Make a file in site root: manifest.json:

Code: [Select]
{
  "background_color": "navy",
  "description": "Site Description",
  "display": "standalone",
  "icons": [
    {
      "src": "images/app_logo.png",
      "sizes": "200x200",
      "type": "image/png"
    }
  ],
  "name": "Site name",
  "short_name": "App Name",
  "start_url": "https://www.domain.tld/"
}

Add to main index page: (Or index.template.php)

Code: [Select]
<link rel="manifest" href="https://www.domain.tld/manifest.json" />
Title: Re: Chrome shortcut
Post by: emanuele on July 29, 2023, 03:38:08 am
PWA are more than just an icon IIRC?
Though I've been a bit sleepy on mobile stuff (and other stuff too) for quite a while. :-\