Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Writing from Perl to an Open Window

Status
Not open for further replies.

Rick7

IS-IT--Management
Apr 15, 2003
16
US
Hi, All:

I have spent much time Googling today trying to find out how to write data from a Perl Script to an existing HTML window. Well, I gave up on Google. There must be a way to do it.

Any help would be much appreciated!!!

Rick

 
If I output HTML from Perl it usually spawns a new window.

My question: Lets say that I use Javascript to open an HTML window (so I have the window handle) can I direct my output from a Perl program to that open window? It would be nice if I could direct to output to a specific region of the page by using an element's ID, but it would not be a problem if I needed to re-write/replace the HTML in the window.

Thanks,

Rick
 
Are you calling your script from the new page? If so, and you don't have any perl code that is creating a new page, then the script output should appear in the open HTML page.

There's always a better way. The fun is trying to find it!
 
Yes. The script would be called from the open window. If you use the print <<HTML; or just print commands from perl, it creates a new window. How do I direct it to write to an already open window/page? More specifically, how do I get write to a specific area of a page?

On this open page, it will ask a series of questions. I would like the answers/output to be written to the open page. I did not really want to re-create the page each time.


Rick
 
If you want to dynamically write to the open page without re-loading then you are talking javascript.

You could experiment with FRAMES or IFRAMES so that only a section of the open window is re-loaded? This adds a little complexity to the HTML code however it may be what you need?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top