Home | Scripts | Tutorials | Books | Hosting | Forums | Links|

Navigation:

Home
Source code
Tutorials
RSS feeds
Articles
Wordpress plugins
Blog
Books
Software
Downloads
Hosting
manuals
Script directory
Training
Our Links






 
 

SPONSORS



 
 

Display the world population

Here is the script

<?php
//this script will dispaly the worlds population
//this is the url with the info
$url = "http://www.census.gov/cgi-bin/ipc/popclockw/index.html";
//open this file to read
$fp = fopen($url, "r");
$search = fread($fp, 50000);
fclose($fp);
//search for the tags which surround the figure
$search = ereg("<p><H1>(.*)</H1>", $search, $content);
echo "<H1>$content[1]</H1>!;
?>

And here is the output