{"repo":"duzun/hQuery.php","free":true,"listed":false,"github":"https://github.com/duzun/hQuery.php","clone":"git clone https://github.com/duzun/hQuery.php.git","description":"An extremely fast web scraper that parses megabytes of invalid HTML in a blink of an eye. PHP5.3+, no dependencies.","language":"PHP","stars":360,"topics":["hquery","crawler","scraper","html","parser","psr-4","psr-0","php","selectors","domcrawler"],"license":"MIT","category":"scrapers-browser-automation","readme_excerpt":"hQuery.php ========== An extremely fast and efficient web scraper that can parse megabytes of invalid HTML in a blink of an eye. You can use the familiar jQuery/CSS selector syntax to easily find the data you need. In my unit tests, I demand it be at least 10 times faster than Symfony's DOMCrawler on a 3Mb HTML document. In reality, according to my humble tests, it is two-three orders of magnitude faster than DOMCrawler in some cases, especially when selecting thousands of elements, and on average uses x2 less RAM. See tests/README.md. API Documentation 💡 Features - Very fast parsing and lookup - Parses broken HTML - jQuery-like style of DOM traversal - Low memory usage - Can handle big HTML documents (I have tested up to 20Mb, but the limit is the amount of RAM you have) - Doesn't require cURL to be installed and automatically handles redirects (see hQuery::fromUrl()) - Caches response for multiple processing tasks - PSR-7 friendly (see hQuery::fromHTML($message)) - PHP 5.3+ - No dependencies Requirements - PHP 5.3 or newer (PHP 7.4+ recommended) - mbstring extension is recommended for reliable charset handling and conversions - Ensure a sufficient memory limit when working with very large documents 🛠 Install Add the library to your project and include it, or install via Composer/npm. Using Composer (recommended): Or include manually: Or via npm: Then require the file from node modules if needed. ⚙ Usage Basic setup: I would recommend using php-http/cache-plugin with a PSR","default_branch":null,"files":null,"tree":[],"storefront":"/r/duzun","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/duzun/hQuery.php/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}