I have one regex which allows one Upper case, one Lower case, 8-16 characters and Most special characters including space. I want add allow space in the regex.
I have tried :
My regex is as follow :
(?=^.{8,16}$)(?=.*[\!\"\#\$\%\&\'\(\)\*\+\,\-\.\/\:\;\<\>\=\?\@\[\]\{\}\\\\\^\_\`\~\|])(?=.*[a-z])(?=.*[A-Z])(?!.*\s)[0-9a-zA-Z\!\"\#\$\%\&\'\(\)\*\+\,\-\.\/\:\;\<\>\=\?\@\[\]\{\}\\\\\^\_\`\~\|]]*$
I just want to add space in this. I have tried \s
and [ ]?
but nothing works.
I have checked the regex
on https://regex101.com/
Any suggestions would be appreciated.