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

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find UK postal code format verification
Expression
(([A-Z]{1,2}[0-9][0-9A-Z]?)\ ([0-9][A-Z]{2}))|(GIR\ 0AA)
Description
Accurate UK postal code format verification. UK postal codes have two parts. The right part is formatted as DLL (L:letter D:digit) and the left part has six alternative formats: LD, LDL, LDD, LLD, LLDL and LLDD. There is only one exception to these formats: GIR 0AA.
Matches
M2 5BQ | EC1A 1HQ | GIR 0AA
Non-Matches
M2 BQ5 | E31A 1HQ | GIR0AA
Author Rating: The rating for this expression. Vassilis Petroulias
Source
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-2014, RegexAdvice.com | ASP.NET Tutorials