php-simple-html-dom-parser
php-simple-html-dom-parser copied to clipboard
Cannot find tags that have additional classes
find method cannot find tag that has additional classes.
For example, I want to find all tags that have 'services' class:
<div class='services'> or
<div class='services last-item'> or
<div class='services active'>
But, If I run:
$html->find('div[class=services]');
I will only get one result:
<div class='services'>
You need to use .services or div[class~=services]: https://github.com/voku/simple_html_dom/commit/5b1854e3a5540db70342c639b8326622ce57b842