I want to read all tag attributes with the word title, HTML sample below
<html>
<head>
<title> </title>
</head>
<body>
<div title="abc"> </div>
<div>
<span title="abcd"> </span>
</div>
<input type="text" title="abcde">
</body>
</html>
I have tried this regex function, which doesn't work
preg_match('\btitle="\S*?"\b', $html, $matches);