Regular Expression that supports multiple currency formats
问题 I have a regular expression that needs to validate if the text is in a supported currency format. ^(\$|€|Fr.|£|kr|R?)\s*((([1-9](,\d{3}){3})|([1-9]\d{0,2}(,\d{3}){0,2})|(\d{1,10}))(\.\d{1,2})?)\s*(\$|€|Fr.|£|kr|R?)$ I support the following: US Dollar (10000.00 or 10,000.00 or $10,000.00) Euro (10000.00 or 10,000.00 or €10,000.00) Francs (10000.00 or 10'000.00 or Fr.10'000.00) Pounds (10000.00 or 10'000.00 or £10,000.00) Kroner (10000,00 or 10'000.00 or 10.000,00 kr) Rand (10000.00 or 10,000