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.
如何使用正则表达式在文本框中允许斯堪的纳维亚字符?我使用了以下代码。但它不允许诸如ä或之类的字符ö
ä
ö
var charexp = /^[a-zA-ZäöüÄÖÜ ]+$/; if(!charexp.test(cus_fname)) { $("#cus_fname_div").html("Only characters are allowed."); }
请帮忙。
var charexp = /^[a-zA-Z\u00E4\u00F6\u00FC\u00C4\u00D6\u00DC ]+$/;