I have a specific validation scenario.
The first character of the string should not contain special characters which I can achieve using /^[!@#$%^&*()_+\-=\[\]{};':"\\|,.<>\/?]+$/
But subsequent characters should not contain specific special characters, which are !@$%^*+=\[\]{};:\\|<>?
I tried that using regex /^[!@#$%^&*()_+\-=\[\]{};':"\\|,.<>\/?][!@$%^*+=\[\]{};:\\|<>?]+$/ and negating the result but its not working.
I want to allow all other characters other than these special characters so I am trying to negate the result of above regex.
What I mean is, first character should accept everything except special character and subsequent chars should accept everything except specified special characters.