Parsing six figure Ordnance Survey Grid Reference input -


an extensive search has produced no answer question, "is there class or function parses input soundness relating uk ordnance survey grid references". uk mapped uk ordnance survey produce detailed maps of united kingdom many types of referencing. 1 of these commonly used 6 figure grid reference, @ so896804. use postcode (zip) checker make sure information entered postcode field sound, can't find same os grid reference. such grid reference function exist, or down tools , write one? thank you.

since tagged "parsing", rather using gis-like tag, i'd reasonably valid os grid reference corresponds regular expression:

(h[ptuwxyz]|n[abcdfghjklmnorqstuwxyz]|ov|s[cdehjkmnoprstuvwxyz]|t[afglmqrv])([0-9]{6}) 

if prepared accept 4-digit 100ha blocks six-digit 1ha blocks, replace second parenthesized expression ([0-9]{4}|[0-9]{2}).

of course, of two-letter blocks marine. ignore ov, example. nw contains little bit of dumfries & galloway (portpatrick, nw995545), , larger irrelevant part of northern ireland.


Comments

Popular posts from this blog

toolbar - How to add link to user registration inside toobar in admin joomla 3 custom component -

linux - disk space limitation when creating war file -