Package

Propaganistas Laravel Phone

Adds phone number functionality to Laravel based on Google's libphonenumber API.

Package

propaganistas/laravel-phone

View on GitHub →

Overview

What Propaganistas Laravel Phone does

Laravel Phone enhances Laravel applications by integrating comprehensive phone number functionality using Google's libphonenumber library.

The package addresses the challenge of validating and formatting international phone numbers within Laravel applications. Using the phone keyword in validation rules, or the Rule class, developers can ensure inputted phone numbers adhere to specific formats and originate from designated countries. This feature is particularly useful for applications requiring phone number validation based on dynamic user input or specific country constraints.

Incorporating the package into a Laravel project allows developers to take advantage of attribute casting, which casts phone numbers to objects for easy manipulation. This means phone numbers can be stored in E.164 format or as raw input, depending on the use case, making data handling both flexible and consistent. The package provides two cast classes that automatically convert values between raw input and formatted numbers, which is essential for maintaining data integrity in databases.

Laravel Phone also offers a utility class that wraps phone numbers with additional methods for formatting and country-specific handling. Developers can format numbers for international dialing, or ensure compatibility with mobile devices by adjusting format based on the intended country of use. These capabilities make it straightforward to implement phone number functionality across various parts of an application, from input validation to user display, aligning with typical internationalization needs.

For developers working with Laravel applications that require nuanced phone number handling, Laravel Phone is a valuable tool. Whether the need is simple validation or complex international formatting, the package's integration with Laravel’s validation ecosystem and database capabilities provides a comprehensive solution.

This overview was generated by AI from the package README and may not reflect the latest release.

Read the full README →

Propaganistas Laravel Phone Related Articles

Phone Number Formatting, Validation, and Model Casts in Laravel image

Phone Number Formatting, Validation, and Model Casts in Laravel

Read article
Building an Interactive Voice Response System with Laravel and Nexmo image

Building an Interactive Voice Response System with Laravel and Nexmo

Read article
Send Laravel Notifications as a Phone Call image

Send Laravel Notifications as a Phone Call

Read article
Text-To-Speech calls with Laravel and Nexmo image

Text-To-Speech calls with Laravel and Nexmo

Read article
Laravel 9.7 Released image

Laravel 9.7 Released

Read article
Mask Sensitive Eloquent Attributes on Retrieval in Laravel image

Mask Sensitive Eloquent Attributes on Retrieval in Laravel

Read article

PhpStorm

The go-to PHP IDE with extensive out-of-the-box support for Laravel and its ecosystem.

PhpStorm

Let your users buy domains without leaving your app

If your Laravel app gives users a site, a storefront, or a workspace, they’ll eventually want their own domain. The name.com API lets them search, register, and connect one without leaving your product. It’s a clean REST API, so Laravel’s HTTP client is all you need.

Let your users buy domains without leaving your app

Acquaint Softtech

Acquaint Softtech offers AI-ready Laravel developers who onboard in 48 hours at $3000/Month with no lengthy sales process and a 100 percent money-back guarantee.

Acquaint Softtech

Shift

Running an old Laravel version? Instant, automated Laravel upgrades and code modernization to keep your applications fresh.

Shift

Harpoon: Next generation time tracking and invoicing

The next generation time-tracking and billing software that helps your agency plan and forecast a profitable future.

Harpoon: Next generation time tracking and invoicing

Kirschbaum

Providing innovation and stability to ensure your web application succeeds.

Kirschbaum