The ASPSmith's Blog

Some rants about ASP.NET by Steven Smith

Regular Expressions

Regular expressions are very powerful, and are one of my favorite tools to use because they are so flexible and they can be used regardless of whether one is a .NET developer or a Unix shell scripter or a Java developer or whatever.  As I started getting into regular expressions for validation controls, I noticed that there wasn't any online library for these expressions, which of course meant that a lot of people were reinventing the wheel.  How many times do different people need to come up with the same (or very close) expression for an email address or a ZIP code, for crying out loud?  So I used this problem to test out my then-novice ASP.NET skills and created an online regular expression library, RegExLib.com.

RegExLib is now over a year old and has quite a few expressions listed and a decent amount of traffic each week.  I'm looking for ideas for how I can improve it.  Since I'll be speaking on regular expressions in May at ASP.NET Connections, and I intend to provide attendees with a regex cheat sheet, one feature I intend to add to the RegExLib.com site is the cheat sheet I'll be handing out (as a printable web page).  I also am aware of a few bugs that need fixed - those are on hold until my Cookbook is done (see yesterday for more on that...).

Anyway, since I'm sure I have a huge audience reading this, please check out RegExLib.com and let me know what you think and how I could make it better.  It really is just a simple little app at the moment with perhaps 15-20 hours of time invested in it.  Since it's getting popular and has enough expressions to make it somewhat useful now, I'm interested in putting some more time into it to make it better.  Thanks for any constructive input.

Comments

Curtis Swartzentruber said:

hey Steve,

That's a great resource. My only suggestion might be to also allow some sort of directory type browsing (Dates, Phone Numbers, Address, etc) and maybe also an option to break things down by Country. I see a lot of variations for the different ways things are done around the world. This would be easy to implement when expressions are submitted (Choose Category, Choose Country (with n/a or any as an option)) It's not that hard to just search now, but as it grows it will be helpful to have the option to drilldown to just what you want.
# February 7, 2003 10:50 AM

Michelle Kinsey-Clinton said:

heh, heh. I just sent you an email perhaps 30 minutes ago asking for a note to specify which reg ex implementations/languages an expression had been tested with... then did a Google search for a regular expression cheat sheet I could bookmark for the next time I need to hack an expression ColdFusion chokes on... this blog entry came up on the first page of results!

Now I don't feel so selfish about having written to demand icing on a very fine cake :D Thanks for the cheat sheet too... and good luck at your conference, which I see starts today. Synchronicity in blogland is a lovely thing.
# May 6, 2003 10:47 AM
Leave a Comment

(required) 

(required) 

(optional)

(required)