Iam making a webcrawler and I need to extract the metadata that contains the description, this is what I did:
$html = file_get_contents('http://www.google.com');
preg_match('/<meta name="description" content="(.*)"/>\i', $html, $description);
$description_out = $description;
var_dump($description_out);
and I get this error
Warning: preg_match(): Unknown modifier '>' in C:\xampp\htdocs\webcrawler\php-web-crawler\index.php on line 21
What is the correct regular expression?