Reply to Re: loading screen

Your name:

Reply:


Posted by Petr Vileta on 10/26/06 00:26

"Laurent Haan" <laurent.haan@gmail.com> píse v diskusním príspevku
news:1161806661.859981.265940@f16g2000cwb.googlegroups.com...
> This effect can't be realised by only using PHP, since PHP is a
> server-side language and the loading screen appears client side.
> Yet, it is possible to achieve such an effect by using javascript and
> CSS and having php invoke the necessary functions to enable/disable the
> loading screen.
>
> What you need to do is design the loading screen in css and hide it
> initially. As soon as you start the section in php where the loading
> screen is ment for, you send the html code to the client that invokes
> the javascript function that displays the loading screen. Finally, at
> the end of the php script, you send the invokation to the javascript
> function that hides the loading screen again.
>
Other way is to place small image eg. 10x1 pixel to page and into very long
html content time by time put javascript for resizing image width. Some like
this:

<html>
<head>
<script>
function resizeit(x) {
image=getElemtById("bar");
image.width=x;
}
</script>
</head>
<body>
Loading: <img id="bar" src="some_green_image.gif" height=10 width=1>
<p>...some long html content here</p>
<script>resizeit(5)</script>
<p>...some other long html content here</p>
<script>resizeit(10)</script>
....
<script>resizeit(100)</script>

--

Petr Vileta, Czech republic
(My server rejects all messages from Yahoo and Hotmail. Send me your mail
from another non-spammer site please.)

[Back to original 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

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