1

I'd like to ask how to create a clickable shortcut in a folder (or desktop) to open a browser with a switch, pointing to a specific webpage.

Below example refers to open a webpage in a Single Site Browser (-ssb). But this could also be in kiosk-mode, such as using the -kiosk switch

In Windows, you right-click anywhere, on the desktop or in a folder to create a shortcut and type the following: "C:\Program Files\Mozilla Firefox\firefox.exe" -ssb https://askubuntu.com/questions/ask"

Q: How does the corresponding step by step procedure looks like in Ubuntu (>18.04) ?


I have tried below

In other posts it is referred to a shortcut to firefox, but this necessary needs to live in the application folder, such as this post: How to create desktop shortcut for Firefox 79 on Ubuntu 20.04

And I am not permitted to drag and drop

"Drag and Drop is not supported / an invalid drag type was used"

when dragging the little keylock left of the address bar (https://askubuntu.com/questions/ask) in Firefox to a folder within Documents folder How to create a desktop shortcut to a website

Below is promising but refer to a short-cut key, but very easy way of doing it How do i create a keyboard shortcut to open a chrome app?

Jaco
  • 123

2 Answers2

0

You can write a simple line script for that purpose.

  1. Create a file (name it whatever you want to and where ever you want)

    #!/bin/bash
    

    You can add "-kiosk" flag after firefox to open the window in kiosk mode

    firefox "https://www.askubuntu.com" #(add any URL you want)

  1. Give execute permissions with chmod +x filename
  2. Then right click on file then --> properties --> permissions --> and tick on Allow executing file as a program
  3. Then go to Open With tab and select Run Software as the default application to open the file with.

Now, you can click twice on the file to directly open link you desire in firefox

0

Solution for your dock or application launcher (a .desktop file)

Option 1: Replacing the existing Firefox launcher

This method gives you the option to launch kiosk mode the same way you can launch private browsing - by right-clicking the icon on the dock or the application launcher and choosing a separate option there.

  1. Copy the current desktop file (probably from /usr/share/applications/firefox.desktop) to ~/.local/share/applications/firefox.desktop.
  2. Open it with a text editor.
  3. Add this section to the end of the file:
[Desktop Action new-kiosk-window]
Name=Open a Kiosk Mode Window
Exec=firefox -kiosk
  1. Find this line in the file:
Actions=new-window;new-private-window;

and replace it with

Actions=new-window;new-private-window;new-kiosk-window;
  1. Save & exit. Log out of OS, log in.

Option 2: Adding an alternative Firefox kiosk launcher

Same as above, but:

  • Rename the file to /.local/share/applications/firefox_kiosk.desktop instead of having the same name.
  • Change the Name= and Description= to something you want and the Exec= line to firefox -kiosk instead of other changes to the firefox_kiosk.desktop file. If you want, you can also change the Icon=.
Carolus
  • 600