KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I know I can validate against string with words ( 0-9 A-Z a-z and underscore ) by applying W in regex like this: function isValid(str) { return /^\w+$/.test(str); } But how do I check whether the string contains ASCII characters only? ( I think I'm close, but what did I miss? ) Reference: https://stackoverflow.com/a/8253200/188331 UPDATE : Standard character set is enough for my case.
Tags (comma-separated)
Save Edits
Cancel