View Single Post
  #2 (permalink)  
Old 01-14-05, 04:36 AM
Beck Beck is offline
Newbie Coder
 
Join Date: Jan 2005
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
of course you can do it...

firstly u have to open it with fopen and put all content of that page into a variable...

and u should use some regexp to parse(html and other unnecessary parts) it.... eventually u're gonna get info which u had wanted...

there is an example which i used 2 years ago...

<?PHP
$euro = fopen("http://www.eurosport.com/home/pages/V3/L0/S22/E5123/standingCh_Lng0_Spo22_Evt5123_Grp30.shtml","r");

$yaz = false;
$cnt = 0;

while(!feof($euro))
{
$cnt++;
if(($cnt>146) && ($cnt<164)){
$yaz = true;
}
else
{
$yaz = false;
}

$line = fgets($euro, 512);
$line = trim($line);
$line = strip_tags($line, '<head>');

if(($line != "") && ($yaz == true)){
$pos = strpos($line, ">");
$sonuc = substr($line,$pos,"50");
echo $sonuc;
echo "<hr color=\"orange\">";
}
}

?>
Reply With Quote