Skip to content

Latest commit

 

History

History
38 lines (28 loc) · 1.95 KB

README.md

File metadata and controls

38 lines (28 loc) · 1.95 KB

Number Format To Decimal

Total Downloads Latest Stable Version License

Number Format To Decimal

The Number Format to Decimal converter is a versatile tool designed to simplify the process of converting numerical values from various formats into a standardized decimal format. This functionality is particularly beneficial for professionals working with data, finance, or programming, where precise numerical representation is crucial.

"Buy Me A Coffee"

Install

composer require davidvandertuijn/number_format_to_decimal

Usage

number_format_to_decimal('1000,99'); // 1000.99
number_format_to_decimal('1000.99'); // 1000.99
number_format_to_decimal('1.000,99'); // 1000.99
number_format_to_decimal('1,000.99'); // 1000.99
number_format_to_decimal('10.000'); // 10000
number_format_to_decimal('100.000'); // 100000
number_format_to_decimal('10,000'); // 10000
number_format_to_decimal('100,000'); // 100000
number_format_to_decimal('1.000.000'); // 1000000
number_format_to_decimal('1.000.000,99'); // 1000000.99
number_format_to_decimal('1,000,000'); // 1000000
number_format_to_decimal('1,000,000.99'); // 1000000.99

Comments

I use this script for many years, if you have a better solution please let me know!