PHPackages                             ujjwal/h-commons - 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. ujjwal/h-commons

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

ujjwal/h-commons
================

A Zend Framework 2 module which contains some usefull abstract classes that can be used across multiple modules

1.3.2(12y ago)01422PHPPHP &gt;=5.3.3

Since Dec 9Pushed 12y agoCompare

[ Source](https://github.com/ojhaujjwal/HCommons)[ Packagist](https://packagist.org/packages/ujjwal/h-commons)[ Docs](https://github.com/ojhaujjwal/HCommons)[ RSS](/packages/ujjwal-h-commons/feed)WikiDiscussions master Synced today

READMEChangelog (7)Dependencies (1)Versions (8)Used By (0)

HCommons
========

[](#hcommons)

A Zend Framework 2 module which contains CSV render strategy to export data to csv format and image strategy to output image. This module also contains some useful abstract classes and some useful snippets that can be used across multiple modules.

This module is deprecated
-------------------------

[](#this-module-is-deprecated)

\##Installation

- Add `"ujjwal/h-commons": "dev-master"` to your composer.json and run `php composer.phar update`
- Enable the module in `config/application.config.php`

\##Features

- Csv Render Strategy to export data to csv format
- Image Strategy to output image with [WebinoImageThumb](https://github.com/webino/WebinoImageThumb)

#### Csv Render Strategy to export data to csv format.

[](#csv-render-strategy-to-export-data-to-csv-format)

Exporting to csv format was never easy. But, now it is!

For example, from your controller:

```
    $csv =  new CsvModel($data);
    $csv->setFileName('my_file_name');
    return $csv;
```

Where, `$data` is a class implementing `Traversable` or an array whose elements are rows of CSV file!

#### Image Strategy to output image with [WebinoImageThumb](https://github.com/webino/WebinoImageThumb)

[](#image-strategy-to-output-image-with-webinoimagethumb)

`Note`: To use this you must install `WebinoImageThumb`. See [this link](https://github.com/webino/WebinoImageThumb)

For example, from your controller:

```
    $image =  new ImageModel();
    $image->setFileName('my_file_name.png');// you can use jpeg || jpg || png || gif
    return $image;

// or you can do
    $image =  new ImageModel();
    $thumbnailer = $this->getServiceLocator()->get('WebinoImageThumb');
    $thumb = $thumbnailer->create("path/to/file");
    $thumb->resize($size, $size);// size in pixel
    $image->setPhpThumb($thumb);
    return $image;
```

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity63

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 ~6 days

Total

7

Last Release

4548d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/4995501?v=4)[Ujjwal Ojha](/maintainers/ojhaujjwal)[@ojhaujjwal](https://github.com/ojhaujjwal)

---

Top Contributors

[![ojhaujjwal](https://avatars.githubusercontent.com/u/4995501?v=4)](https://github.com/ojhaujjwal "ojhaujjwal (55 commits)")

---

Tags

zf2

### Embed Badge

![Health badge](/badges/ujjwal-h-commons/health.svg)

```
[![Health](https://phpackages.com/badges/ujjwal-h-commons/health.svg)](https://phpackages.com/packages/ujjwal-h-commons)
```

###  Alternatives

[slm/google-analytics

Google Analytics tracking integration for Zend Framework 2

4080.3k](/packages/slm-google-analytics)

PHPackages © 2026

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