Regular expression, How to allow combination of dot (period) and letters?

前端 未结 7 611
庸人自扰
庸人自扰 2020-12-31 08:30

I want to allow (.) and (a-zA-Z) letters and _ and - , I have some problems with the (.) ,

Any idea ?

Thanks in advance ,

Ish

7条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-31 09:18

    This should work just fine:

      [A-z._\-]+
    

    Please be aware that you my have to escape that slash depending on your programming language.

提交回复
热议问题