PHPackages                             shenoto/validation - 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. [Validation &amp; Sanitization](/categories/validation)
4. /
5. shenoto/validation

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

shenoto/validation
==================

Laravel 4.2 persian validation

v0.1(8y ago)0121PHPPHP &gt;=5.4.0

Since Jun 29Pushed 8y ago1 watchersCompare

[ Source](https://github.com/Rasool-Geek/laravel-persian-validation)[ Packagist](https://packagist.org/packages/shenoto/validation)[ RSS](/packages/shenoto-validation/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

Laravel 4 Persian Validation
============================

[](#laravel-4-persian-validation)

Laravel 4 Persian Validation provides validation for Persian alphabet, number and etc.

Requirement
-----------

[](#requirement)

- Laravel 4.\*
- PHP 5.5 &gt;=

License
-------

[](#license)

Laravel Persian Validation is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)

Install
-------

[](#install)

Via Composer

```
$ composer require Shenoto/Validation
```

Config
------

[](#config)

Add the following provider to providers part of config/app.php

```
Shenoto\Validation\ValidationServiceProvider
```

vendor:publish
--------------

[](#vendorpublish)

You can run vendor:publish command to have custom lang file of package on this path ( resources/lang/validation )

Usage
-----

[](#usage)

You can access to validation rules by passing the rules key according blew following table:

RulesDescriptionspersian\_alphaPersian alphabetpersian\_numPersian numberspersian\_alpha\_numPersian alphabet and numbersiran\_mobileIran mobile numbersshebaIran Sheba numbersmelli\_codeIran melli codeis\_not\_persianDoesn't accept Persian alphabet and numberslimited\_arrayCheck variable is array and array must be lesser and equal than parameterunsigned\_numCheck variable is unsigned numbersalpha\_spaceAccept Persian, English and ... alphabet, space charactera\_urlCheck correct URLa\_domainCheck correct DomainmoreCheck value be max and not equal toolessCheck value be min and not equal tooiran\_phoneIran phone numberscard\_numberPayment card numbersaddressAccept Persian, English and ... alphabet, Persian and English numbers and some special charactersiran\_postal\_codeIran postal codepackage\_nameCheck APK package name### Persian Alpha

[](#persian-alpha)

Accept Persian language alphabet according to standard Persian, this is the way you can use this validation rule:

```
$input = [ 'فارسی' ];

$rules = [ 'persian_alpha' ];

Validator::make( $input, $rules );

```

### Persian numbers

[](#persian-numbers)

Validate Persian standard numbers (۰۱۲۳۴۵۶۷۸۹):

```
$input = [ '۰۱۲۳۴۵۶۷۸۹' ];

$rules = [ 'persian_num' ];

Validator::make( $input, $rules );

```

### Persian Alpha Num

[](#persian-alpha-num)

Validate Persian alpha num:

```
$input = [ 'فارسی۱۲۳۴۵۶۷۸۹' ];

$rules = [ 'persian_alpha_num' ];

Validator::make( $input, $rules );

```

### Iran mobile phone

[](#iran-mobile-phone)

Validate Iran mobile phones (irancel, rightel, hamrah-e-aval, ...):

```
$input = [ '09381234567' ];

$rules = [ 'iran_mobile' ];

Validator::make( $input, $rules );

```

### Sheba number

[](#sheba-number)

Validate Iran bank sheba numbers:

```
$input = [ 'IR062960000000100324200001' ];

$rules = [ 'sheba' ];

Validator::make( $input, $rules );

```

### Iran national code

[](#iran-national-code)

Validate Iran national code (melli-code):

```
$input = [ '3240175800' ];

$rules = [ 'melli_code' ];

Validator::make( $input, $rules );

```

### Payment card number

[](#payment-card-number)

Validate Iran payment card numbers:

```
$input = [ '6274129005473742' ];

$rules = [ 'card_number' ];

Validator::make( $input, $rules );

```

### Iran postal code

[](#iran-postal-code)

Validate Iran postal code:

```
$input = [ '167197-35744' ];

$rules = [ 'iran_postal_code' ];

Validator::make( $input, $rules );

$input = [ '16719735744' ];

$rules = [ 'iran_postal_code' ];

Validator::make( $input, $rules );

```

More
----

[](#more)

Here is full list of Anetwork validation rules usage:

```
Validator::make( $request->all(), [

  'name'          => 'persian_alpha|unique|max:25', // Validate Persian alphabet, unique and max to 25 characters

  'age'           => 'persian_num|required',  // Validate Persian numbers and check it's required

  'city'          => 'persian_alpha_num|min:10',  // Validate persian alphabet & numbers at least 10 digit accepted

  'mobile'        => 'iran_mobile', // Validate mobile number

  'sheba_number'  => 'sheba', // Validate sheba number of bank account

  'melli_code'    => 'melli_code',  // Validate melli code number

  'latin_name'    => 'is_not_persian',  // Validate alphabet and doesn't contain Persian alphabet or number

  'your_array'    => 'limited_array:2', // Validate your array variable and must be contian 2 member or lesser

  'url'           => 'a_url', // Validate url

  'domain'        => 'a_domain',  // Validate domain

  'more'          => 'more:10', // Validate value be more than parameter

  'less'          => 'less:10', // Validate value be less than parameter

  'phone'         => 'iran_phone', // Validate phone number

  'card_number'   => 'card_number', // Validate payment card number

  'address'       => 'address' // validate Persian, English and ... alphabet, Persian and English numbers and some special characters

  'postal_code'   => 'iran_postal_code' // validate iran postal code format

  'package_name'  => 'package_name' // validate APK package name

]);
```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity48

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

Unknown

Total

1

Last Release

3242d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/10c6ae4de71ee34e457e46b65e280204aa4559ae551a1eb5bd5450aeab9f5d34?d=identicon)[Rasool\_pack](/maintainers/Rasool_pack)

---

Top Contributors

[![rasool1994](https://avatars.githubusercontent.com/u/20123076?v=4)](https://github.com/rasool1994 "rasool1994 (6 commits)")

### Embed Badge

![Health badge](/badges/shenoto-validation/health.svg)

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

###  Alternatives

[spatie/laravel-honeypot

Preventing spam submitted through forms

1.6k6.0M60](/packages/spatie-laravel-honeypot)[proengsoft/laravel-jsvalidation

Validate forms transparently with Javascript reusing your Laravel Validation Rules, Messages, and FormRequest

1.1k2.3M49](/packages/proengsoft-laravel-jsvalidation)[stevebauman/purify

An HTML Purifier / Sanitizer for Laravel

5325.6M19](/packages/stevebauman-purify)[axlon/laravel-postal-code-validation

Worldwide postal code validation for Laravel and Lumen

3853.3M1](/packages/axlon-laravel-postal-code-validation)[sunspikes/clamav-validator

Custom Laravel 5 anti-virus validator for file uploads.

3651.8M3](/packages/sunspikes-clamav-validator)[laravel-validation-rules/credit-card

Validate credit card number, expiration date, cvc

2412.2M5](/packages/laravel-validation-rules-credit-card)

PHPackages © 2026

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