Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我希望 reg 限制用户,和@
,
@
我试过[^,@]了,它不起作用。
[^,@]
您应该使用[^,@]+而不是,[^,@]因为这+将允许正则表达式搜索整个字符串,而不仅仅是第一个值。
[^,@]+
+