Search by

theplankmeister / balanced-html-tags

theplankmeister

Checks whether or not the HTML tags in the passed HTML fragment are balanced.

This package's canonical repository appears to be gone and the package has been frozen as a result. Email us for help if needed.

Package info

github.com/theplankmeister/balanced-html-tags

pkg:composer/theplankmeister/balanced-html-tags

Statistics

Installs: 182

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

dev-master 2015-12-07 13:47 UTC

This package is auto-updated.

Last update: 2024-11-06 09:27:38 UTC


README

A simple HTML validator that checks that tags are balanced. Use the two available static methods:

$isBalanced = BalancedHtmlTags::tagsBalanced('<div>one<p></div>'); //false
$balanced = BalancedHtmlTags::balanceTags('<div>one<p></div>'); //<div>one<p></p></div>

Version

1.0.0

License

MIT