This section illustrates you how to escape all special characters from the given string or text. Here, you can learn the way of detecting all special characters present in the given string.
This section provides an example for the best illustration about the way of matching special characters in the given string or text. This program finds special characters and replaces all the detected special characters by "F" character and display whole string with the "F" character place of any special characters in the given string or text.
This method compiles a regular expression "[^a-zA-Z0-9 ]" which does not detects a to z, A to Z and 0 to 9 characters, means it detects all special symbols or characters.
Here is the code of the program:
Rs. 20,000 US$ 300
Today: Rs. 10,000 US$150
Course Duration: 30 hrs
Posted on: February 22, 2008 If you enjoyed this post then why not add us on Google+? Add us to your Circles