View Single Post
  #2 (permalink)  
Old 06-26-09, 03:34 AM
Nico's Avatar
Nico Nico is offline
Community Leader
 
Join Date: Sep 2005
Location: Spain
Posts: 7,536
Thanks: 5
Thanked 20 Times in 18 Posts
PHP Code:
'~^\d{4}[ ]?[a-z]{2}$~i' 
And get used to preg_match() rather than the ereg* functions. They're way slower and they're gonna be disabled by default (or removed completely, not sure) in PHP 6.
Reply With Quote