RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find Full Name Parser
Expression
^(?<title>.*\.\s)*(?<firstname>([A-Z][a-z]+\s*)+)(\s)(?<middleinitial>([A-Z]\.?\s)*)(?<lastname>[A-Z][a-zA-Z-']+)(?<suffix>.*)$
Description
Finds title, first name, middle initial, last name, and suffix of a name. Middle names are added to first name. Uses .Net capture group names.
Matches
Mary, Mary White, Mary Jo White, Dr. Mary Jo White, Dr. Mary Jo T. White, Ph.D.
Non-Matches
Mary Jo Thomas White
Author Rating: The rating for this expression. Jamison White
Source Jamison White
Your Rating
Bad Good

Enter New Comment

Title

Name

Comment

Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Copyright © 2001-2025, RegexAdvice.com | ASP.NET Tutorials