%s";
if($url)
$s = fetch_url($url);
if(! $s) {
echo sprintf($template,$url,$url);
killme();
}
$dom = HTML5_Parser::parse($s);
if(! $dom)
return $ret;
$items = $dom->getElementsByTagName('title');
foreach($items as $item) {
$title = $item->textContent;
break;
}
echo sprintf($template,$url,$title);
killme();
}