Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
Created·2020-03-22 06:35
Flavor·JavaScript

/
(?:^[1-9]([0-9]+)?(?:\.[0-9]{1,2})?$)|(?:^(?:0){1}$)|(?:^[0-9]\.[0-9](?:[0-9])?$)
/
Open regex in editor

Description

数字/货币金额 (只支持正数、不支持校验千分位分隔符)

Submitted by anonymous