PHPackages                             fghazaleh/cport - 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. fghazaleh/cport

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

fghazaleh/cport
===============

PHP support library for Array and String PHP function

1.1.0(4y ago)566MITPHPPHP &gt;=7.2.0CI failing

Since Jul 12Pushed 4y ago1 watchersCompare

[ Source](https://github.com/fghazaleh/cport)[ Packagist](https://packagist.org/packages/fghazaleh/cport)[ RSS](/packages/fghazaleh-cport/feed)WikiDiscussions master Synced today

READMEChangelog (3)Dependencies (1)Versions (4)Used By (0)

cport
=====

[](#cport)

cport is a PHP support library wrapping Array and String PHP functions.

```
$string = 'This is my first string';

$str = new \FG\Support\Strings\Str($string);
// or
$str = \FG\Support\Strings\Str::fromString($string);
```

Build-in methods in `Str` class.

- trim, rtrim, ltrim
- length
- toUpper, toLower, toUpperFirst, toLowerFirst
- replace
- subString
- appendAfter, appendBefore
- stripTags
- reverse
- toMd5
- startsWith, endsWith
- indexOf
- lastIndexOf
- charAt, charCodeAt
- camel, studly
- contains, any
- pad
- parseQueryString

```
$array = [1, 2, 3, 4];

$arr = new \FG\Support\Arrays\Arr($array);
// or
$arr = \FG\Support\Arrays\Arr::createFrom($array);
```

Build-in methods in `Arr` class.

- add
- merge
- slice
- map
- each
- where
- column
- combine
- diff
- flip
- sort
- whereSort
- keys, keyExists
- first, last
- all, count
- sum

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

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

Total

3

Last Release

1678d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4fb2cc76ffbd3dbe7edc1e55d544281924e9ba52601168d01fcd094f229d6a78?d=identicon)[fghazaleh](/maintainers/fghazaleh)

---

Top Contributors

[![fghazaleh](https://avatars.githubusercontent.com/u/27064820?v=4)](https://github.com/fghazaleh "fghazaleh (27 commits)")

---

Tags

php

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/fghazaleh-cport/health.svg)

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

###  Alternatives

[yahnis-elsts/plugin-update-checker

A custom update checker for WordPress plugins and themes. Useful if you can't host your plugin in the official WP repository but still want it to support automatic updates.

2.5k1.5M79](/packages/yahnis-elsts-plugin-update-checker)[2bj/phanybar

Control AnyBar from your php

627.4M2](/packages/2bj-phanybar)[ghanem/rating

Rating system for Laravel

8615.5k](/packages/ghanem-rating)[microman/kirby-column-blocks

Use columns in block fields based on the layout field.

422.5k](/packages/microman-kirby-column-blocks)[bangerkuwranger/magento-2-1-3-category-limit-bug-workaround

Workaround for bug from v2.1.3 that arbitrarily limits indexed products in category to 500

1414.0k](/packages/bangerkuwranger-magento-2-1-3-category-limit-bug-workaround)

PHPackages © 2026

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