suppose i echo out
$url = "http://www.mydomain.com";
echo file_get_content($url);
and http://www.mydomain.com has a div i.e
<title>sitename</title>
</head><body>
Lorem Ipsum.......
<div id="divname">and here is div content</div>
Copyright bla bla bla
no i want to only fetch content between div with id=”divname” how can i do that
Of course you could still use
file_get_contentsorcurlif you want to introduce error checking on the fetch of the document.