What regex can I use to match only letters, numbers, and one space between each word?

前端 未结 6 905
遇见更好的自我
遇见更好的自我 2021-02-01 05:01

How can I create a regex expression that will match only letters and numbers, and one space between each word?

Good Examples:



        
6条回答
  •  执念已碎
    2021-02-01 05:31

    (?:[a-zA-Z0-9]+[ ])+[a-zA-Z0-9]+
    

    If I understand you correctly the above regex should work. See screenshot below:

    screenshot http://img136.imageshack.us/img136/6871/screenshotkiki056.png

提交回复
热议问题