You are here: Re: Progress indicators on a page...? « PHP Programming Language « IT news, forums, messages
Re: Progress indicators on a page...?

Posted by Chuck Anderson on 06/22/06 19:03

no@emails.thx wrote:
> On Tue, 20 Jun 2006 12:32:23 -0400, Jerry Stuckle
> <jstucklex@attglobal.net> wrote:
>
>
>> no@emails.thx wrote:
>>
>>> Hi
>>>
>>> I have a PHP script that updates a very large table and in the code I
>>> echo some text to show the progress of the update but the text only
>>> appears when the page has finished displaying.
>>>
>>> Is there any way (through html headers?) to force the page to update
>>> in real time, while the PHP script is still executing?
>>>
>>> I have seen similar thngs on webmin pages when it is downloading
>>> updates and it is nothing fancy (graphics etc) - just text.
>>>
>>> Thanks
>>> Chris R.
>>>
>> As Henrik indicated, flush() works. You may also need to call ob_flush().
>>
>
> Hi Henrik & Jerry
>
> I tried ob_flush() followed by flush(), as suggested but it dodn't
> make a difference - still got a blank page for 5 minutes than SPLAT! a
> full page listing all the imported records.
>
> Another poster on a different group suggested it might be because I
> use nested tables to arrange the content on the page. Apparently
> browsers often refuse to display the cells until the </table> is
> received.
>
> With that in mind I might look at using Ajax or just reworking the
> pages using CSS to position blocks of content on the page. :o)
>
> Cheers, Chris R.
>
Not Php, but .....

If you want to use an animated gif as a "dumb" progress bar, here is
some css that does it.
http://www.cssplay.co.uk/menu/start_gif.html (using a.hover and a.click)

You can also use Javascript to start and stop an animated gif (let me
know if you want to see this method).

Or another Javascript method:
http://www.irt.org/script/1225.htm

--
*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Everyone's journey should be different,
so that we all are enriched
in new and endless ways
*****************************

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация