01<?php 02 03// the adress of the remote file to read 04$off_site='http://fundisom.com/g5/'; 05 06// you have to backslash certain characters ! 07$start='<title>'; 08$end='<\/title>'; 09 10$fp=fopen($off_site,'r')ordie('Unable to open file '.$off_site.' for reading'); 11$cont=''; 12 13while(!feof($fp)) 14{ 15$buf=trim(fgets($fp,4096)); 16$cont.=$buf; 17} 18 19preg_match('/'.$start.'(.*)'.$end.'/s',$cont,$match); 20 21echo' 22 <p> 23 the title of '.$off_site.' is:<br /> 24 <strong>'.$match[1].'</strong> 25 </p>'; 26 27?>