LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-13-2012, 11:00 AM   #1
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Rep: Reputation: 11
Any Suggestions??


I am using opensuse 12.1 here at work to run a machine that's sole purpose is too open Firefox with a certain web address and that's pretty much it. So for now I am using a bash script I wrote that tells Firefox what URL to go to using:
export DISPLAY=:0
firefox http://<URL name>
then set up a cron job that runs that script and for the most part it works, just not like how i need it to work. The URL that I am telling Firefox to go then launches two other windows, and this is where I am having an issue. I am trying to get it to where one window opens on the left screen and the other window opens on the right screen, right now its open two the main URL on the left and the two secondary windows on the right Im wondering if it would be worth my time and sanity to try and write a script using java or something similar to tell it what to do with the two windows, or just keep fussing with the way I am doing it.

Thanks for any suggestions and help to this minor frustration I am having.
 
Old 07-13-2012, 11:52 AM   #2
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
Could you not find the URLs of the popups and display them separately? I realise that means messing with Firefox profiles to get two instances running but it would allow you to open them where you wanted.
 
Old 07-13-2012, 12:14 PM   #3
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Original Poster
Rep: Reputation: 11
I have tried to open the popup's separately and all it does is still open them both on either the right side or the left side, I am looking for a way to always have them open up one on the right and one on the left. I have not tried to mess with the firefox profiles, can you expand a little more on this idea for me please.
 
Old 07-13-2012, 12:21 PM   #4
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
What I meant was run something like:
Code:
export DISPLAY=:0.0
firefox http://<URL of first popup>
export DISPLAY=:0.1
firefox http://<URL of second popup>
But, if you do this Firefox may complain about there being an instance running already, though this just happens with certain twin-head setups I think and the answer would be to create separate profiles.
This thread touches on what I am suggesting:
http://www.linuxquestions.org/questi...splays-789402/
 
1 members found this post helpful.
Old 07-13-2012, 12:38 PM   #5
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Original Poster
Rep: Reputation: 11
I will try that and see what happens, thank you for the tip.
 
Old 07-13-2012, 02:01 PM   #6
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Original Poster
Rep: Reputation: 11
Ok i have tried using the suggested code and I get the error cannot open DISPLAY =:0.1, I also tried it on my test machine that has the same setup and I get the same error. My test machine is using a nvidia card that has the correct drivers and X config, my other machine is just using the on board video.
 
Old 07-13-2012, 02:11 PM   #7
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
Ah, shame, that trick should work if you're running as two separate X sessions. You could try echoing display on booth monitors and seeing if there is a way to differentiate them.
otherwise, I'm out of ideas I'm afraid.
 
Old 07-13-2012, 02:24 PM   #8
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Original Poster
Rep: Reputation: 11
No worries man, I do appreciate the suggestions. On my test machine I do have the two monitors configured as separate X screens, not sure if that is the same as separate x sessions. Either way I am gonna keep looking at what I can do and hope for the best.
 
Old 07-14-2012, 01:50 AM   #9
Valery Reznic
ELF Statifier author
 
Registered: Oct 2007
Posts: 676

Rep: Reputation: 137Reputation: 137
Quote:
Originally Posted by 273 View Post
What I meant was run something like:
Code:
export DISPLAY=:0.0
firefox http://<URL of first popup>
export DISPLAY=:0.1
firefox http://<URL of second popup>
But, if you do this Firefox may complain about there being an instance running already, though this just happens with certain twin-head setups I think and the answer would be to create separate profiles.
This thread touches on what I am suggesting:
http://www.linuxquestions.org/questi...splays-789402/
You can try to add -no-remote option to firefox
 
1 members found this post helpful.
Old 07-23-2012, 02:24 PM   #10
JimiSc
LQ Newbie
 
Registered: Jun 2012
Location: New Mexico
Distribution: openSuse 12.1
Posts: 18

Original Poster
Rep: Reputation: 11
I have finally fixed my issue. Ok so the biggest thing I was missing was the Xinerama setting in the xorg.conf file. I had it set to "1" thus allowing me to drag windows over and what not and that was preventing me from actually being able to designate DISPLAY=:0.0 and DISPLAY=:0.1. Got it turned off and rebooted and viola it works. The next thing I had to set up was separate profiles in Firefox. Now all that is said and done I can now tell Firefox to open a separate window in both screens. Thank you all for the feed back to my little dilemma I was having.
 
Old 07-23-2012, 02:28 PM   #11
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
Darn, I should have thought about Xinerama, I run separate X servers because whilst being able to move windows between monitors is useful not knowing which monitor a window will open on is too annoying.
Glad you're moving towards a solution . If your problem is solved, you should probably mark this thread solved.

Last edited by 273; 07-23-2012 at 02:29 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:01 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration