https://github.com/olegmarko/phone-validator
Laravel Phone Validation
https://github.com/olegmarko/phone-validator
laravel laravel-package laravel-validation phone-validation
Last synced: 2 months ago
JSON representation
Laravel Phone Validation
- Host: GitHub
- URL: https://github.com/olegmarko/phone-validator
- Owner: OlegMarko
- License: mit
- Created: 2017-11-15T14:30:02.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-11-16T22:26:14.000Z (over 7 years ago)
- Last Synced: 2025-02-08T01:18:57.472Z (3 months ago)
- Topics: laravel, laravel-package, laravel-validation, phone-validation
- Language: PHP
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
Laravel Phone Validator (most phone number formats)
## Introduction
Phone Validator is a simple validator phone number.
## Installation
To get started with Phone Validator, simply run:
composer require fixik/phone-validator
Next, register the `Fixik\Validator\PhoneValidatorServiceProvider` in your `config/app.php` file:
```php
'providers' => [
// Other service providers...Fixik\Validator\PhoneValidatorServiceProvider::class,
],
```## Basic Usage
From your validator use method `phone`
## Add validation message
`resources/lang/en/validation.php`
```php
'phone' => 'The :attribute field contains an invalid phone number'
```## License
Phone Validator is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)