MozillaZine

Nice Red Hat tip - make Firebird the GLOBAL default browser

User Help for Mozilla Firefox
Guest
Guest
 

Post Posted November 16th, 2003, 3:35 pm

If you're tired of Firebird asking you which profile you want to use when you click a web link, read on..

Red Hat 8 and 9 ship with something called htmlview. It allows you to run "htmlview" from the console, or anywhere else, and for the default browser to be run.
You can configure the default browser for all users by editing /etc/htmlview.conf, or for an individual user by editing ~/.htmlviewrc

To use, you need to change the following:
1. If you have a desktop or panel icon, change the command that is run to "htmlview %u"
2. Under Red Hat> Preferences> Preferred Applications, change the web browser to "htmlview %s"

I use FireBird as default for all users, so I edit /etc/htmlview.conf, here are the contents:
X11BROWSER=/usr/local/bin/htmlview-cheat

I then create a file named /usr/local/bin/htmlview-cheat, with the following contents:
/usr/local/MozillaFirebird-0.7/MozillaFirebird -remote "openurl($1, new-tab)"

Make it executable:
chmod +x /usr/local/bin/htmlview-cheat

Now whenever you click a link in Ximian Evolution, or just about anywhere, Firebird will run - creating a new tab, and not asking you which profile you want to use. :)

Guest
Guest
 

Post Posted November 16th, 2003, 3:51 pm

htmlview-cheat needs to contain the following to make it work when fb is not open:

FB="/usr/local/MozillaFirebird-0.7/MozillaFirebird"
URL="$@"

$FB -remote "ping()"

if [ $? = 0 ] ; then
$FB -remote "openurl($URL, new-tab)"
else
$FB "$URL"
fi

Guest
Guest
 

Post Posted November 16th, 2003, 3:55 pm

ping() is slow. You could use pgrep instead.

Guest
Guest
 

Post Posted November 17th, 2003, 1:05 pm

Use the following in /usr/local/bin/htmlview-cheat

FB="/usr/local/MozillaFirebird-0.7/MozillaFirebird"
URL="$@"

$FB -remote 'openURL('$URL', new-tab)' || $FB $URL &

Return to Firefox Support


Who is online

Users browsing this forum: No registered users and 7 guests