Use [^A-Za-z0-9]
.
Note: removed the space since that is not typically considered alphanumeric.
More Related Contents:
- how to write regex for this expression in java
- Regular expression for SSN and phone number [closed]
- Regex for converting xml tags key to camel case
- How do i find the first un-escaped quotes in Java?
- Incrementing only the digits from an alphanumeric string
- Specific String validation using regex
- Regexp Java for password validation
- Create array of regex matches
- Split string into array of character strings
- List of all special characters that need to be escaped in a regex
- Regular expression to match URLs in Java
- Using Java to find substring of a bigger string using Regular Expression
- Regex date format validation on Java
- Detect and extract url from a string?
- What is the regex for “Any positive integer, excluding 0”
- Extract string between two strings in java
- Is Java Regex Thread Safe?
- How to extract parameters from a given url
- How to use java regex to match a line
- How to remove the backslash in string using regex in Java?
- Regex pattern including all special characters
- Java; String replace (school project)?
- Remove all non-“word characters” from a String in Java, leaving accented characters?
- java.util.regex.PatternSyntaxException: Dangling meta character ‘+’ near index 0 +
- How to match repeated patterns?
- How to escape a square bracket for Pattern compilation?
- String.replaceAll is considerably slower than doing the job yourself
- Remove all occurrences of \ from string
- Extract ip addresses from Strings using regex
- Validate if input string is a number between 0-255 using regex