Follow along with the video below to see how to install our site as a web app on your home screen.
Бележка: This feature may not be available in some browsers.
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "ТУКА-URL-АДРЕСА");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 0);
$output = curl_exec($ch);
preg_match("/\<title\>(.*)\<\/title\>/is", $output, $matches);
print_r($matches);
curl_close($ch);
<?php
header("Content-Type: text/html; charset=windows-1251");
$url = "http://web-tourist.net/";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 0);
$output = curl_exec($ch);
preg_match("/\<title\>(.*?)\<\/title\>/is", $output, $matches[]);
preg_match("/\<meta name=\"description\" content=\"(.*?)\"/is", $output, $matches[]);
curl_close($ch);
echo $matches[0][1]."---- TITLE <br />";
echo $matches[1][1]."---- META DESC";
?>
<title>
YouTube
- Wiz Khalifa - Black And Yellow [G-Mix] ft. Snoop Dogg, Juicy J & T-Pain
</title>
kWo_2 каза:Работи!Но защо от youtube не изкарва нищо? Нито title нито desc
Ето така е при тях
<title>
YouTube
- Wiz Khalifa - Black And Yellow [G-Mix] ft. Snoop Dogg, Juicy J & T-Pain
</title>
YouTube - Wiz Khalifa - Black And Yellow [G-Mix] ft. Snoop Dogg, Juicy J & T-Pain ---- TITLE
© 2011 Distributed By WMG http://www.wizkhalifa.com---- META DESC