PHPackages                             walecloud/rating - 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. walecloud/rating

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

walecloud/rating
================

A rating system that can be integrated with any customer satisfaction and feedback system

221[1 issues](https://github.com/waleCloud/Rating/issues)PHPCI failing

Since Oct 12Pushed 6y ago2 watchersCompare

[ Source](https://github.com/waleCloud/Rating)[ Packagist](https://packagist.org/packages/walecloud/rating)[ RSS](/packages/walecloud-rating/feed)WikiDiscussions master Synced 4d ago

READMEChangelogDependenciesVersions (4)Used By (0)

Rating
======

[](#rating)

[![Build Status](https://camo.githubusercontent.com/cb1590c04e4c192a47b972ce37623e4d7ff3407255a4606986b06a8951a24730/68747470733a2f2f7472617669732d63692e6f72672f77616c65436c6f75642f526174696e672e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/waleCloud/Rating) [![CircleCI](https://camo.githubusercontent.com/3093ac212e059586e247a5e12070cf78dd402b89933e6df0837cd44c7334824a/68747470733a2f2f636972636c6563692e636f6d2f67682f77616c65436c6f75642f526174696e672f747265652f6d61737465722e7376673f7374796c653d737667)](https://circleci.com/gh/waleCloud/Rating/tree/master)[![Maintainability](https://camo.githubusercontent.com/da0eae41ae550bf5baeab13b7944aa6830e2df6cc549d4315445302a64bc890b/68747470733a2f2f6170692e636f6465636c696d6174652e636f6d2f76312f6261646765732f34613937346338613834356562393133663461652f6d61696e7461696e6162696c697479)](https://codeclimate.com/github/waleCloud/Rating/maintainability)[![Test Coverage](https://camo.githubusercontent.com/081d5accf0d148e58349462e27e9d68961262d9b43bb411a585257bc4b5e5d9f/68747470733a2f2f6170692e636f6465636c696d6174652e636f6d2f76312f6261646765732f34613937346338613834356562393133663461652f746573745f636f766572616765)](https://codeclimate.com/github/waleCloud/Rating/test_coverage)

A rating system that can be integrated with any customer satisfaction and feedback system

Options
-------

[](#options)

- Numeric: Similar to how star ratings work, you can customize it to have different ranges starting from 1- 3,4,5...99999.
- Voting: For Like or Dislike, Upvote or Downvote.

### Usage

[](#usage)

`require '../vendor/autoload.php';`

`use App\CreateRating;`

- For `NUMERIC, RANGE` based rating, click [here](numericStrategy.php)

`$initialiseRating = new CreateRating('number'); // number rating`

`$rating = $initialiseRating->index(1, 10);`

`echo $rating->rate(5);` // returns the rating provided

`$ratingsKeyValuePairList = array ( '5' => 7, 4 => 2, 3 => 2, 2 => 2, 1 => 2, );``echo $rating->getAverage($ratingsKeyValuePairList);` // returns the average rating, provided arrays of ratings in key value pairs.

- For `Voting, Like/Dislike` based rating, click [here](votingStrategy.php)

`$initialiseRating = new CreateRating('vote');` // voting rating

`$rating = $initialiseRating->index();` // no need to supply any argument

`echo $rating->rate(true);` // accepts 1/0, true/false returns 1 or 0

`$ratingVal = array( 1,true,false, 0, 0, 0, 0,1,1,1,1,1 );`

`echo $rating->getAverage($ratingVal);` // takes in array of reactions, (true, false, 1, 0) returns `(yes=>7, no=>5)`

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance10

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 95% 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/6704567?v=4)[Walecloud](/maintainers/walecloud)[@waleCloud](https://github.com/waleCloud)

---

Top Contributors

[![waleCloud](https://avatars.githubusercontent.com/u/6704567?v=4)](https://github.com/waleCloud "waleCloud (38 commits)")[![bluemorbo](https://avatars.githubusercontent.com/u/16987132?v=4)](https://github.com/bluemorbo "bluemorbo (2 commits)")

---

Tags

customer-satisfactiondislikedownvotefeedbackhacktoberfestlikeopen-sourcephpratingrating-starsrating-systemupvotevote-ratingvoting

### Embed Badge

![Health badge](/badges/walecloud-rating/health.svg)

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

###  Alternatives

[phpu/calendar

中国日历，通过天文计算和民间推算方法，准确计算出公历-1000年至3000年的农历、干支、节气等，同时支持多配置、多语言、多时区。

201.7k](/packages/phpu-calendar)

PHPackages © 2026

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