In this tutorial, Sam shows you how to use Regular Expressions.
By : Sam Fullman
There are a bunch of good elementary tutorials out there on Regular Expressions. Just do a search at google.com.
However, what I am about to share encapsulates many of the frustrations I encountered in developing expressions that would work every time, and that always captured any variant in the string I was searching.
So if you're banging your head against the monitor even after you have read other articles, this is the one to read. You can think of this as the advanced class. If you're looking to get file strings off the web and do editing or analysis, you need to know this stuff. You may not always need to be this complex when you develop regex'es, but if you'll study the concepts, you can be assured you've learned something, and have the confidence you'll find what you're looking for (if it's there).