Hmmm ... that won't works ... [[:space:]]* won't ring the bell ...
This is the right answer :
<?
$str = "your html code here .... <TITLE>bla bla bla</TITLE>";
preg_match_all("/<title>([<]*)/i",$str,$arr,PREG_SET_ORDER);
print $arr[0][1];
?>
rgds,
LexZEUS
http://lexzeus.tripod.com/
paul wrote:
function get_title($html)
{
$ary_html = spliti("(<title>)[[:space:]]|[[:space:]](</title>)",$html);
return $ary_html[1];
}
i havent tested this but it should work... it will allow the title tags and actual titles to be on different lines and the case of the tags will not matter...
-paul
http://xhawk.net