CVS: phpweather currentimage.php,1.1,1.2 index.php,1.40,1.41 test.php...
Brought to you by:
iridium
From: Martin G. <gim...@us...> - 2003-10-07 22:31:58
|
Update of /cvsroot/phpweather/phpweather In directory sc8-pr-cvs1:/tmp/cvs-serv28692 Modified Files: currentimage.php index.php test.php Log Message: From GIF to PNG images all around. Index: currentimage.php =================================================================== RCS file: /cvsroot/phpweather/phpweather/currentimage.php,v retrieving revision 1.1 retrieving revision 1.2 diff -u -3 -r1.1 -r1.2 --- currentimage.php 4 Jun 2002 12:11:27 -0000 1.1 +++ currentimage.php 7 Oct 2003 22:31:54 -0000 1.2 @@ -1,28 +1,26 @@ <?php /* -* currentimage.php -* Return the current weather icon directly. - Can be used from -* HTML rather than PHP files. -* -* Use: <img src="currentimage.php?icao=abcd" /> in your html -* + * currentimage.php + * Return the current weather icon directly. - Can be used from + * HTML rather than PHP files. + * + * Use: <img src="currentimage.php?icao=abcd" /> in your html + * */ error_reporting(E_NONE); require('phpweather.php'); +require(PHPWEATHER_BASE_DIR . "/output/pw_images.php"); -$weather = new phpweather(array()); +$weather = new phpweather(); +$weather->set_icao($icao); - $weather->set_icao($icao); - - include(PHPWEATHER_BASE_DIR . "/output/pw_images.php"); - $icons = new pw_images($weather, array()); - header('Content-Type: image/gif'); - header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past - header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always modified - header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 - header("Pragma: no-cache"); // HTTP/1.0 - readfile($icons->get_sky_image()); - +$icons = new pw_images($weather); +header('Content-Type: image/png'); +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past +header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always modified +header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 +header("Pragma: no-cache"); // HTTP/1.0 +readfile($icons->get_sky_image()); ?> Index: index.php =================================================================== RCS file: /cvsroot/phpweather/phpweather/index.php,v retrieving revision 1.40 retrieving revision 1.41 diff -u -3 -r1.40 -r1.41 --- index.php 2 Sep 2003 18:06:08 -0000 1.40 +++ index.php 7 Oct 2003 22:31:54 -0000 1.41 @@ -19,7 +19,7 @@ </head> <body> -<img src="icons/phpweather-long-white.gif" width="187" height="50" +<img src="icons/phpweather-long-white.png" width="187" height="50" alt="PHP Weather" align="right" /> <h1>PHP Weather Test Page</h1> Index: test.php =================================================================== RCS file: /cvsroot/phpweather/phpweather/test.php,v retrieving revision 1.7 retrieving revision 1.8 diff -u -3 -r1.7 -r1.8 --- test.php 14 Jun 2003 23:35:38 -0000 1.7 +++ test.php 7 Oct 2003 22:31:54 -0000 1.8 @@ -7,7 +7,7 @@ </head> <body> -<img src="icons/phpweather-long-white.gif" width="187" height="50" +<img src="icons/phpweather-long-white.png" width="187" height="50" alt="PHP Weather" align="right" /> <h1>PHP Weather Test Page</h1> |