saeedafzal/htmldomparser

Html DOM Parser for PHP 7.1.x

dev-contribute 2020-05-05 09:18 UTC

This package is auto-updated.

Last update: 2025-07-05 21:18:15 UTC


README

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.