?
Solved

Display page as it is loading

Posted on 2003-02-20
3
Medium Priority
?
138 Views
Last Modified: 2013-12-25
I have a script that copies files from one server to another.  I want to display the status of these copies "as they are happening" ....
like
Copy of File ABC started..
Copy of file ABC completed successfully

Copy of File DEF started
Copy in progress......

my script will not write the page to the screen as it is loading ...only after all files are completed and I write the </html> tag.

how do I get around this ...and write the screen as it is happening..
0
Comment
Question by:Durell
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 2

Accepted Solution

by:
BassTeQ earned 200 total points
ID: 7991784
This is probably a bit messy but it should work.
What Id do is put all the filenames I want to transfer into an array.

Then loop through the array one file at a time, once you've got the filename, use javascript to add a paramater to the end of your script script.cgi?file=file1.zip and reload it with this new paramater.

Then when your script reloads it picks up that file contains a variable called file1.zip, so then execute the code to do then, then refresh the page and change the file name to script.cgi?file=file2.zip and so on.

This way you wont have to wait for all the files to transfer until you see results on the page.

Sorry I cant provide a code example, bit busy at the moment, but hopefully my explaination will help you out.

Cheers
0

Featured Post

Python: Series & Data Frames With Pandas

Learn the basics of Python’s pandas library of series & data frames and how we can use these tools for data manipulation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial will discuss fancy secure registration forms, with AJAX technology support. In this article I assume you already know HTML and some JS. I will write the code using WhizBase Server Pages, so you need to know some basics in WBSP (you mig…
In threads here at EE, each comment has a unique Identifier (ID). It is easy to get the full path for an ID via the right-click context menu. However, we often want to post a short link within a thread rather than the full link. This article shows a…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question