RE: Iconize weather info and something else
Brought to you by:
iridium
From: Max H. <ma...@fl...> - 2002-02-10 20:55:46
|
> >I've actually got something working - take a look at > > > > http://www.gimpster.com/php/phpweather/demo2.php?sleep=5 > > > >The idea is this: <snip> That was exactly what I had in mind earlier :) > One suggestion though, you flush the page each time the function > wait_for_report is called. To me, it seems that that is only > required once: > immediately after the </html> tag. The page is then sent to the > browser, and > the browser can start processing a complete page. > > Hmmm, while typing this, I'm not so sure anymore: doesn't the browser > disconnect from the server when a complete page is received? If so, the > remaining stuff (js with metar data) is not received anymore.... No, flush() flushes the output buffer, it doesn't tear down the TCP connection. I agree that it's only needed once, though, after the static elements have been written. But one thing: the <script> elements should be *within* the <html> element. All the browsers I know will render a page before they receive the final </html> anyway. Did you all note that this won't work on windoze servers anyway? I assume that the sleep() is just there so we can see what's going on? Max |