SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Addict
    Join Date
    Dec 2009
    Posts
    301
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    HTML 5 telephone number

    HTML 5 telephone number validation:


    <input type='tel' pattern="[0-9]{10,10}" class="search" name="number" autocomplete="off" required>

    can you please tell what does 10,10 mean here ? what is first 10 for and what is second 10 for here ?

  2. #2
    Gre aus'm Pott gold trophysilver trophybronze trophy
    Pullo's Avatar
    Join Date
    Jun 2007
    Location
    Germany
    Posts
    5,861
    Mentioned
    206 Post(s)
    Tagged
    12 Thread(s)
    Hi,

    {n,m} matches when the preceding character occurs at least n times but not more than m times.
    In this case that makes the second 10 redundant.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •