Regex pattern to remove special character

when i tried your pattern… it gives the actual input