Reply to Re: Iframe refresh questions...

Your name:

Reply:


Posted by Toby Inkster on 10/02/05 11:35

Max wrote:

> Website A: UP
>
> I'd like the UP to be an iframe without a border so that it appears as
> though it's all the same page. The iframe has some PHP code that pings the
> site, and then prints UP or Down.

Seems a bit OTT. Why do you need an iframe at all? What's wrong with
putting this in the main page itself:

<?php
$host = 'websitea.example.org';
$ping = `ping -c1 -q '$host'`;

print "<strong>Website A:</strong> ";
print (strstr($ping, '1 packets transmitted, 1 received'))
? '<var style="color:#090;background:#cfc">UP</var>'
: '<var style="color:#900;background:#fcc">DOWN</var>';
?>

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact

[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

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