Results 1 to 4 of 4

Thread: maskRe for a textfield

  1. #1
    Sencha User
    Join Date
    Jun 2012
    Posts
    12

    Default maskRe for a textfield

    Hi all. I have a textfield and I`m using this maskRe maskRe: /^([a-zA-Z0-9_\s\-]*)$/, to allow users type only english alphabet characters, but I also need to allow them type characers from their own language like:
    , , , and some other characters from Turkish and Serbian alphabet also.

    Can you please tell me how can I build a maskRe for doing that?

    Thank You and I hope you will help me!

  2. #2
    Sencha User sword-it's Avatar
    Join Date
    May 2012
    Location
    Istanbul
    Posts
    1,335

    Default Is it possible

    Can you try this reg:

    Code:
    maskRe: /^([a-zA-Z0-9{,?,,?,}_\s\-]*)$/,
    sword-it.com, Sencha Developer House in Turkey - Istanbul University Technopark Suite 204.

  3. #3
    Sencha User
    Join Date
    Jun 2012
    Posts
    12

    Default

    Thank you for your answer. I tried this but it didn`t work for me. I found the solution in this way:
    maskRe: /^([a-zA-Z0-9_\s\-\\\\]*)$/

  4. #4
    Sencha User
    Join Date
    Jun 2012
    Posts
    12

    Default Regular expression in textfield.

    I have a text field with this maskRe and ERgular Expression:

    maskRe: /^([0-9 \/]*)$/
    regex: /^[0-9]*([0-9]*\/?[0-9]*)[0-9]$/

    I need to allow user write a string in this form: number/number.
    It allows only one '/' and starts with number and ends with number

    Can you help me because the regEx above it`s not working as it should

Posting Permissions

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