Tag Archives: alphanumerics

Alpha-numerics Only

This is an old piece of code thats degenerate now, but i cam struggling to find a working replacement.

It goes through the string and removes anything that isn’t A-Z or 0-9 (alphanumerics) . Any Additions between the square brackets will also not be removed. eg [^A-Za-z0-9&] would also not remove & symbols.