HTML5 form validation pattern alphanumeric with spaces?

后端 未结 7 2135
借酒劲吻你
借酒劲吻你 2020-12-08 00:10

I have the following input tag in my html5 form:

7条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-08 00:48

    How about adding a space in the pattern attribute like pattern="[a-zA-Z0-9 ]+". If you want to support any kind of space try pattern="[a-zA-Z0-9\s]+"

提交回复
热议问题