Page 1 of 1

[Solved] Default webbrowser?

PostPosted: Apr 11th, '13, 05:41
by janpihlgren
How do I do to change from Firefox to Opera as default webbrowser?
And how do I do to have Opera as start when clicking on a *.html-file?

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 08:40
by RoyD
Have you tried System Settings, Default Applications, then browse to Opera app? this is unde KDE

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 08:46
by janpihlgren
Yes, but that doesn't work

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 09:49
by RoyD
I just installed Opera and tried my sugestions and you are quite right, it does not work...

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 12:57
by jkerr82508
You also need to change the File Association for .html files. For some reason making Opera the default browser does not raise its position in the list of preferred applications. (It did for google-chrome for me.)

In System Settings - File Associations, search for .htm open the text group, select .html and then move Opera to the top of the list of applications.

Jim

Edit: I recall now that each application has a priority code, which determines its position in the preference list. Opera has been given a lower priority, perhaps because it is in the nonfree repo . google-chrome being a third party rpm has been able to set its priority to the highest, since it is not required to follow Mageia's packaging policies.

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 13:40
by janpihlgren
That's what I have done and it will nor help.

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 14:34
by jkerr82508
janpihlgren wrote:That's what I have done and it will nor help.

That's strange - it works for me. Does it report that it is updating the system configuration, after you click on Apply?

Jim

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 14:43
by janpihlgren
I don't think so. I don't remember.

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 16:10
by jkerr82508
What I would do if I experienced what you are seeing:

Change the default browser to a third browser, konqueror perhaps, and then make it the top of the list of associations.

If that works, try changing the default browser back to opera and make it the top of the list of associations.

Jim

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 16:53
by janpihlgren
When accessing a html-file it open opera.
But when I try to access this inside Thunderburd (e-mail)

If you want to view the newest post made since your last visit, click the
following link:
viewtopic.php?f=7&t=4709&p=32949&e=32949
it will start Firefox as webbrowser. I want Opera as default.
I can't find where to change this.

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 18:06
by oj
For thunderbird try edit->options->attachments tab->incoming. There's options for what to do with file, http and https that default to firefox. I'm not sure if just putting "opera" in there will find the executable, but definitely try it. If it doesn't work try the full path to the opera executable, eg /usr/bin/opera (or wherever it actually is)

Just to be sure, I'd make the change, close thunderbird and reopen before trying a link.

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 20:06
by jkerr82508
On my Mageia 2 installation, Thunderbird - Edit - Preferences - Attachments - Incoming is empty and it seems to be impossible to add anything to it. (Thunderbird opens web links in firefox.)

There are several related bug reports about mime-type associations in the Mozilla applications. I started with this one:

https://bugs.mageia.org/show_bug.cgi?id=2027

but ended up with a headache trying to follow the links to other bugs. :cry:

I think that doktor5000 has been involved in this. Perhaps he knows what the current status is.

Jim

Re: Default webbrowser?

PostPosted: Apr 11th, '13, 20:56
by doktor5000
You need to distinguish between opening a protocol, and a file type.
As file type was already changed, that bug report you linked to is the wrong one.
What you want is for the newer Thunderbird after 3.x partly in https://bugs.mageia.org/show_bug.cgi?id=4461
but maybe more https://bugs.mageia.org/show_bug.cgi?id=2051

Please show the output of
Code: Select all
xdg-settings get default-web-browser

What happens if you run as user in a terminal
Code: Select all
xdg-open http://www.google.com
and
Code: Select all
www-browser http://www.google.com


But overall this is quite messed up, due to the various mechanisms and different implementations for
the different desktops and applications. To get a small glimpse, you may also want to look at https://wiki.archlinux.org/index.php/De ... plications

Re: Default webbrowser?

PostPosted: Apr 12th, '13, 00:03
by jkerr82508
I followed the work-around suggested by Dave Hodgins in:
https://bugs.mageia.org/show_bug.cgi?id=2051#c7
and edited ~./local/share/applications/defaults.list, adding
x-scheme-handler/http=google-chrome.desktop
x-scheme-handler/https=google-chrome.desktop
x-scheme-handler/ftp=google-chrome.desktop

google-chrome is set as my default browser and was already set as the text/html default.
Links in incoming emails in thunderbird now opened in google-chrome.

I then changed the default web browser to opera-browser (which is what started this thread) and set the preferred application for html files to opera. I then changed all instances of "google-chrome" in the defaults.lst file to "opera-browser" and links in thunderbird now opened in opera.

It may be a bit of a fudge, but it does work (at least for opera and google-chrome). I still have to test this in cauldron and before I do I may try to get my head around that Arch wiki article.

(It has never particularly bothered me that links opened in firefox. I'm agnostic about web browsers.)

Jim

Re: Default webbrowser?

PostPosted: Apr 12th, '13, 04:46
by janpihlgren
First:
doktor5000
This is the result:
[jan@Humlan ~]$ xdg-open get default-web-browser
xdg-open: unexpected argument 'default-web-browser'
Try 'xdg-open --help' for more information.
[jan@Humlan ~]$

[jan@Humlan ~]$ xdg-open http://www.google.com
Konqueror opens.

[jan@Humlan ~]$ www-browser http://www.google.com
Konqueror opens


Second:
jkerr82508
This is my ~./local/share/applications/defaults.list after changes:
[Default Applications]
text/x-c++src=Nokia-QtCreator.desktop
application/x-designer=Nokia-QtCreator.desktop
application/vnd.nokia.qt.qmakeprofile=Nokia-QtCreator.desktop
application/vnd.nokia.xml.qt.resource=Nokia-QtCreator.desktop
application/vnd.nokia.qt.creatorproject"=Nokia-QtCreator.desktop
text/x-c++hdr=Nokia-QtCreator.desktop
text/x-xsrc=Nokia-QtCreator.desktop
x-scheme-handler/http=opera.desktop
x-scheme-handler/https=opera.desktop
x-scheme-handler/ftp=opera.desktop
text/html=opera.desktop

Nothing changes, still open firefox
It doesn't bothered me either but I have change to opera because firefox will not read/open a localfile woas.htm which it has done for years but failed after a update of Mageia(bug 9644)
I wan't have two browser running at the same time, that's the reason.

Re: Default webbrowser?

PostPosted: Apr 12th, '13, 08:24
by jkerr82508
x-scheme-handler/http=opera.desktop
x-scheme-handler/https=opera.desktop
x-scheme-handler/ftp=opera.desktop
text/html=opera.desktop

I think that you should use "opera-browser" instead of "opera" in each of those lines.

Jim

Re: Default webbrowser?

PostPosted: Apr 12th, '13, 08:41
by janpihlgren
:D
That's works!
Thanks!!! :!:
:D

Re: Default webbrowser?

PostPosted: Apr 12th, '13, 09:12
by isadora
Jan, please......will you mark the topic accordingly? ;)

Thank you, and a great day!!!! :)