PHPackages                             saeedafzal/htmldomparser - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. saeedafzal/htmldomparser

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

saeedafzal/htmldomparser
========================

Html DOM Parser for PHP 7.1.x

04PHP

Since May 3Pushed 6y ago1 watchersCompare

[ Source](https://github.com/imsaeedafzal/HtmlDomParser)[ Packagist](https://packagist.org/packages/saeedafzal/htmldomparser)[ RSS](/packages/saeedafzal-htmldomparser/feed)WikiDiscussions contribute Synced 1w ago

READMEChangelogDependenciesVersions (2)Used By (0)

HtmlDomParser
=============

[](#htmldomparser)

This library is useful to parse the html templates and override the elements quickly.

*Key Features:*

- Helps to find the elements by class, id and element.
- You can also find the elements by custom xPaths as well.
- Get *innerHtml* content of any element same like you do in jQuery/JavaScript.
- Get *outerHtml* content of any element same like you do in jQuery/JavaScript.
- Overrides the *innerHtml* and *outerHtml* of any elemen same like the way you do in jQuery/JavaScript.
- List of attribtues for the each element within the iteration.
- List of the attributes outside the iteration using main dom object.
- Copy the attribuets of main element with the new one when outerHtml is replaced.
- Copy the attributes inside when innerHtml content is replaced.
- Supports the dirty bad/or dirty html templates too.
- More features coming soon.

*Note: The work is in progress. You all are welcome to contribute to make this library awesome.*

###  Health Score

18

—

LowBetter than 7% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/37543494?v=4)[Saeed Afzal](/maintainers/saeedafzal)[@saeedafzal](https://github.com/saeedafzal)

---

Top Contributors

[![imsaeedafzal](https://avatars.githubusercontent.com/u/1997594?v=4)](https://github.com/imsaeedafzal "imsaeedafzal (22 commits)")

---

Tags

domdocumentphp7praser

### Embed Badge

![Health badge](/badges/saeedafzal-htmldomparser/health.svg)

```
[![Health](https://phpackages.com/badges/saeedafzal-htmldomparser/health.svg)](https://phpackages.com/packages/saeedafzal-htmldomparser)
```

###  Alternatives

[symfony/polyfill-intl-grapheme

Symfony polyfill for intl's grapheme\_\* functions

1.7k773.3M60](/packages/symfony-polyfill-intl-grapheme)[seld/phar-utils

PHAR file format utilities, for when PHP phars you up

875192.0M46](/packages/seld-phar-utils)[savvot/random

Deterministic pseudo-random generators library with dozens of useful functions and several sources of randomness

21274.9k5](/packages/savvot-random)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
