//Making User agent just like google which helps the browser to say which site visit
$options = array('http'=>array('method'=>"GET",'headers'=>"User-Agent: Nir003"));
$context = stream_context_create($options);
// allows you to parse html pages
$doc = new DOMDocument();
// load full page in $doc variable
//download the page
@$doc->loadHTML(@file_get_contents($url,false,$context));
Thats all! your page load into $doc as object
😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍
Now the data is yours ;)
now do what ever you want with this scraped data.
Like here i separate title from $doc :
$title = $doc->getElementsByTagName("title");
$title = $title->item(0)->nodeValue;
echo $title;
// <title> Youtube(nodeValue) </title>
Nice, This is really informative. I was searching for this solution. Finally found it.
উত্তরমুছুনI am really very happy to visit your blog. Directly I am found which I truly need. please visit our website for more information
উত্তরমুছুনTop 5 Best Open Source Web Scraping Framework Tools In 2022
I am really very happy to visit your blog. Directly I am found which I truly need. please visit our website for more information about Web Scraping Service in USA
উত্তরমুছুন