Cannot open firefox from link if it is already running

Chris Kacoroski kacoroski at comcast.net
Thu Sep 2 23:53:24 CEST 2004


Thanks very much.

cheers,

ski

Marc Schwartz wrote:
> On Thu, 2004-09-02 at 16:13, Brian J. Tarricone wrote:
> 
>>On 09/02/04 14:06, Chris Kacoroski wrote:
>>
>>>Hi,
>>>
>>>I am sure there is way to fix this (I do not have the problem with KDE). 
>>>   If I have a firefox window open and then I click on a link in 
>>>another application (e.g. thunderbird, xffm, the panel, etc) I get the 
>>>choose user dialog and cannot open the link unless I exit the existing 
>>>firefox windows.  Other than this, I am completely sold on xfce as it is 
>>>much simpler, easier, and more intuitive than kde or gnome. Thanks for 
>>>your help.
>>
>>this has nothing to do with xfce.  you need some kind of script that will
>>launch firefox properly.  basically it needs to end up doing something like
>>this:
>>
>>firefox -remote "openURL(http://google.com,new-window)"
>>
>>i believe there are much more functional anf featureful scripts floating
>>around that will first check to see if firefox is running, etc.  google is
>>your friend ^_^.
> 
> 
> 
> Here is one:
> 
> #!/bin/sh 
> 
> /usr/include/firefox/firefox -a firefox -remote 'ping()' 
> if [ $? -eq 0 ]; then 
> #open a new window 
> /usr/include/firefox/firefox -a firefox -remote "openurl($1,new-window)"
> else 
> #open new instance 
> /usr/include/firefox/firefox $1 &
> fi
> 
> 
> The above had to be changed (lines 1 and 4) in the recent version of
> Firefox, so be aware of that. The change entails the '-a firefox' part.
> 
> I use the above in a shell script that I put in ~/bin and then set any
> HTML related application preferences (including htmlview) and the 'run
> action' for ROX to that script.
> 
> If you would prefer to open a new 'tab' instead of a new window, change
> 'new-window' in the above to 'new-tab'.
> 
> HTH,
> 
> Marc Schwartz
> 
> 
> _______________________________________________
> Xfce mailing list
> Xfce at xfce.org
> http://lunar-linux.org/mailman/listinfo/xfce
> http://www.xfce.org
> 

-- 
"When we try to pick out anything by itself, we find it
  connected to the entire universe"            John Muir

Chris "Ski" Kacoroski, kacoroski at comcast.net, 435-681-0092



More information about the Xfce mailing list