Community Patterns

Community Library Entry

1

Regular Expression
Created·2014-07-16 12:37
Flavor·PCRE (Legacy)

/
^[0-9][0-9]{0,6}$
/
Open regex in editor

Description

var pattern='/^[0-9][0-9]{0,6}$/'; /* int match 9 digit / /********************************************* *

  • ^ starting point
  • 1st [0-9] number should be start between 0 to 9
  • 2nd [0-9] number should be end between 0 to 9
  • 3nd {0-6} number length should be exact 6 digit
  • $ its show the end of string or data

************************************************/

Submitted by sudhir k gupta