Make external programs in Linux use the right browser: Difference between revisions
From MozillaZine Knowledge Base
Jump to navigationJump to search
mNo edit summary |
(Firebird --> Firefox) |
||
Line 1: | Line 1: | ||
Question: How do I configure external programs in Linux to open URLs in | Question: How do I configure external programs in Linux to open URLs in Firefox? | ||
Answer: Configure each external program to pass the URL to this Bourne shell script: | Answer: Configure each external program to pass the URL to this Bourne shell script: | ||
Line 5: | Line 5: | ||
'#'!/bin/sh<br> | '#'!/bin/sh<br> | ||
'#'<br> | '#'<br> | ||
'#' This script allows external apps to open new URLs in | '#' This script allows external apps to open new URLs in Firefox<br> | ||
'#' or open a new instance of | '#' or open a new instance of Firefox if it isn't already started<br> | ||
'#'<br> | '#'<br> | ||
/home/theonekea/ | /home/theonekea/MozillaFirefox/MozillaFirefox -remote "openURL($@,new-tab)" || | ||
exec /home/theonekea/ | exec /home/theonekea/MozillaFirefox/MozillaFirefox "$@"; | ||
(replace /home/theonekea/ | (replace /home/theonekea/MozillaFirefox with the correct path to your installation of Firefox). | ||
This shell script takes advantage of the Mozilla IPC protocol to either open the external URL in an already-active | This shell script takes advantage of the Mozilla IPC protocol to either open the external URL in an already-active Firefox invocation, or start a new invocation of Firefox. |
Revision as of 19:50, 9 February 2004
Question: How do I configure external programs in Linux to open URLs in Firefox?
Answer: Configure each external program to pass the URL to this Bourne shell script:
'#'!/bin/sh
'#'
'#' This script allows external apps to open new URLs in Firefox
'#' or open a new instance of Firefox if it isn't already started
'#'
/home/theonekea/MozillaFirefox/MozillaFirefox -remote "openURL($@,new-tab)" ||
exec /home/theonekea/MozillaFirefox/MozillaFirefox "$@";
(replace /home/theonekea/MozillaFirefox with the correct path to your installation of Firefox).
This shell script takes advantage of the Mozilla IPC protocol to either open the external URL in an already-active Firefox invocation, or start a new invocation of Firefox.