|
Posted by Carl Vondrick on 10/05/01 11:38
Denebola wrote:
> I want to be able to display an image (with integral link to an
> external site) on my webpage at 08:00:00 Monday and a different image
> (also with integral link to an external site) at, for example,
> 08:10:30 Monday, and again at 08:45:10 Monday etc etc.
You can use the date() function.
http://us3.php.net/manual/en/function.date.php
For example:
// Switch statement based off server time
switch (date('H i s D'))
{
case '08 10 30 Mon':
print 'Image 1';
break;
case '08 45 10 Mon':
print 'Image 2';
break;
}
Depending on how complex you want to get, you can do this by other
means. Can you explain more?
> I also want the clients webpage to refresh as the image changes.
You need some JavaScript for this part. Either use Ajax, reload the
page, or some other system.
- Carl
Navigation:
[Reply to this message]
|