huge has asked for the wisdom of the Perl Monks concerning the following question:

I have a perl app that repeatedly does some text processing, generates some HTML, and then displays the HTML on my screen by opening a browser window with the code:

ActiveState::Browser::open($fullHtmlFileName);

The default browser on my Windows Vista system is Firefox, so this opens a new firefox Tab in the most recently viewed firefox window. If the code is executed again, a new tab is opened, and so on, and so on...

Ideally I'd like to be able to open a new browser *window* the first time that code is executed, and then each subsequent time through the loop I'd like to have firefox (or IE if I have to) just display the new HTML in the same window, without opening a new tab or window.

Actually, I guess the truly perfect behavior would be to check to see if a browser window with a particular title is already open on my machine. If not, open a new one. Then display the HTML in that window.

Can anyone assist me in making this work? thanks in advance...

Replies are listed 'Best First'.
Re: Controling browser behavior from Perl
by Anonymous Monk on Aug 20, 2009 at 12:37 UTC