Jump to content

[SOLVED] Is there a way to update php/html page in realtime?


reakt

Recommended Posts

Hi there, I was previously running on php on IIS and have recently switched over to Apache 2.2. I have a php script that starts with something like:

echo "Processing, please wait...";

It then reads in a text file line by line, outputting the lines to other text files depending on several conditional statements. The input file can be up to 100MB so the script sometimes takes 5-10 mins to run. After the process is complete it goes:

echo "Done!";

 

Previously on IIS when you first loaded the page you would see "Processing, please wait..." while the script processed, then when it finished, you would see on the screen "Processing, please wait...Done!". The word Done having appeared only after the script finished processing.

 

Now since changing to apache when the page loads nothing is displayed on screen for 5-10 minutes while the script is processing, then when it finishes, you get Processing, please wait...Done!" all at once. For some reason it processes the whole script before doing any of the echo commands.

 

Basically I just want to know how I can display something on the screen before the processing begins. Thanks!

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.