PHPackages                             denshoch/utils - 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. denshoch/utils

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

denshoch/utils
==============

Utility class used in Denshoch softwares.

v1.2.0(1y ago)05922MITPHP

Since Aug 27Pushed 1y ago2 watchersCompare

[ Source](https://github.com/denshoch/utils)[ Packagist](https://packagist.org/packages/denshoch/utils)[ RSS](/packages/denshoch-utils/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (3)Versions (11)Used By (2)

Denshoch Utils
==============

[](#denshoch-utils)

Utility class used in Denshoch softwares.

Install
-------

[](#install)

```
composer install

```

Usage
-----

[](#usage)

removeControlChars()
--------------------

[](#removecontrolchars)

Remove Unicode control characters from input text.

```
$text = "&#x0;&#x1";
\Denshoch\Utils::removeControlChars( $text );
var_dump( $text ); #=> ''
```

HtmlModifier
------------

[](#htmlmodifier)

```
$html = "Hello, world!";
$result = \Denshoch\HtmlModifier::addClass($html, 'p', 'my-class');
=> 'Hello, world!'

$html = "Hello, world!";
$tagClassPairs = [
    'p' => 'my-class',
    'div' => 'my-other-class'
];
$result = HtmlModifier::addClassMultiple($html, $tagClassPairs);
=> 'Hello, world!'
```

Test
----

[](#test)

```
vendor/bin/phpunit --bootstrap vendor/autoload.php tests

```

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance36

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity69

Established project with proven stability

 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.

###  Release Activity

Cadence

Every ~253 days

Recently: every ~147 days

Total

10

Last Release

580d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/5093936?v=4)[Densho Channel](/maintainers/denshoch)[@denshoch](https://github.com/denshoch)

---

Top Contributors

[![lostandfound](https://avatars.githubusercontent.com/u/596183?v=4)](https://github.com/lostandfound "lostandfound (19 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/denshoch-utils/health.svg)

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

PHPackages © 2026

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