how to allow only alphanumeric and space in javascript using regex?
Hi Friends 馃憢, Welcome To Infinitbility! 鉂わ笍 To allow only alphanumeric and space, use this regex /^[a-z\d\s]+$/i it will return true if value contain only alphanumeric and spaces. Let鈥檚 see short example to use regex in javascript const regex = /^[a-z\d\s]+$/i; console.log(regex.test("hello 8943")) Today, I鈥檓 going to show you How do I check value contain only alphanumeric and space in javascript, as above mentioned, I鈥檓 going to use the above-mentioned regex with test() method....