You are not logged in.
I found this out when using a script to open a web page, I thought sensible-browser pointed to the users default (preferred) web browser, but every time I use the command it opens konqueror (my default is set to iceweasel). I have found how to change it using
sudo update-alternatives --config x-www-browser
but my question is,
how (in a script) can I call the users preferred (set to default) browser?
I figure this is not a q4os problem as a simple web search guided me to other peoples issues with this on other os's.
Any suggestions welcome
Dai
Offline
Scratch that I found it xdg-open if anyone else is curious
Dai
EDIT: this didn't work, tried it on another system, it only worked as I changed using the command in the previous post...
anybody know anything?
Last edited by Dai_trying (2016-02-17 01:01)
Offline
No problem cc I'm trying to get a web page opened from a bash script.
I can use the two commands mentioned previously, but they do not always use the broswer that the user has set (usually from within the browser preferences) as default. It's not really a big deal as sensible-browser and xdg-open both work. It's just that what they percieve as the users browser is not always the same as the users choice.
I don't want to call a specific browser in my script as it may not always be available, so I wanted a generic name I could use to call the default.
I hope that clears things up a little
Dai
Offline
Set the default browser in:
Control Panel -> KDE Components -> Default applications -> Web browser
Then run:
$ kfmclient openURL http://www.q4os.org
Offline
Thanks @Q4OS Team, but the issue here is I want to open the browser that the user has set as default from within the browser, as this is where most users would set their preference. I can't get my head around why there are so many different areas that preferences can be made but none of them seem to respect the others choice??
Like I said before though it is not really a big issue as a web page is opened, it just might not be in the browser the user prefers to use...
Dai
Offline